Skip to content

Instantly share code, notes, and snippets.

@sakadonohito
Created October 24, 2012 14:27
Show Gist options
  • Select an option

  • Save sakadonohito/3946374 to your computer and use it in GitHub Desktop.

Select an option

Save sakadonohito/3946374 to your computer and use it in GitHub Desktop.
for blog
require 'rfm'
class FMServer
def initialize()
@FM_CONFIG = {
:host => "FileMakerServerの接続先IP",
:account_name => "FileMakerFileのログインアカウント",
:password => "FileMakerFileのログインパスワード",
:database => "FileMakerFileの名前",
:ssl => false,
:root_cert => false,
}
@fm = Rfm::Server.new(@FM_CONFIG)
end
def listAll(lay,sortCond)
return @fm[@FM_CONFIG[:database]][lay].all(sortCond)
end
def create(lay,obj)
@fm[@FM_CONFIG[:database]][lay].create(obj)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment