OpenID Connect Implicit Flow を実装したプロバイダのサンプルアプリケーションです。
http://openid-foundation-japan.github.io/openid-connect-core-1_0.ja.html
OpenID Connect Implicit Flow を実装したプロバイダのサンプルアプリケーションです。
http://openid-foundation-japan.github.io/openid-connect-core-1_0.ja.html
[Tag] json:name, ham:true, spam:false | |
[Value] eggs | |
[Tag] json:version, ham:false, spam:true | |
[Value] 1 |
package main | |
import ( | |
"fmt" | |
"reflect" | |
) | |
type Meta struct { | |
Name string `json:"name" ham:"true" spam:"false"` | |
Version string `json:"version" ham:"false" spam:"true"` |
{[ | |
{ | |
"id" : "urn:ietf:params:scim:schemas:core:2.0:User", | |
"name" : "User", | |
"description" : "User Account", | |
"attributes" : [ | |
{ | |
"name" : "userName", | |
"type" : "string", | |
"multiValued" : false, |
class Hoge | |
def self.hoge | |
obj = Kernel.const_get(klass.capitalize).new | |
attributes.each do |key| | |
obj.send("#{key}=", key.to_s + "!!!") | |
end | |
p obj | |
end | |
def self.klass |
require 'mqtt' | |
host = '127.0.0.1' | |
port = 61613 | |
MQTT::Client.connect(:remote_host => host, :remote_port => port, | |
:username => 'admin', :password => 'password') do |client| | |
client.get('tutorial') do |topic,message| |
require 'mqtt' | |
host = '127.0.0.1' | |
port = 61613 | |
MQTT::Client.connect(:remote_host => host, :remote_port => port, | |
:username => 'admin', :password => 'password') do |client| | |
client.publish('tutorial', 'Hello, Apollo', retain=true) |
def pascalsTraiangle(col: Int, row: Int): Int = { | |
if(col == 0 ){ | |
1 | |
}else if (col == row){ | |
1 | |
}else | |
pascalsTraiangle((col - 1),(row - 1)) + pascalsTraiangle(col, (row - 1)) | |
} |
(defroute task-show ("/tasks/:id" :method :GET) (&key id) | |
"指定されたIDのJSONを返却します。存在しない場合はHTTPステータスコード404を返却します。" | |
(let ((task (find-task-from-db (parse-integer id)))) | |
(if (eq task nil) | |
(progn | |
(setf (status *response*) 404) | |
"") | |
(render-json task)))) | |
(defun find-task-from-db (id) |