Sha256: f0018b0df9e8d2e22348f8958a1bf6f541235ff22e908692f56ef27845ce19bd
Contents?: true
Size: 540 Bytes
Versions: 5
Compression:
Stored size: 540 Bytes
Contents
# frozen_string_literal: true $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib')) $LOAD_PATH.unshift(File.dirname(__FILE__)) require 'rubygems' require 'ncmb' require 'yaml' yaml = YAML.load_file(File.join(File.dirname(__FILE__), '..', 'setting.yml')) NCMB.initialize( application_key: yaml['application_key'], client_key: yaml['client_key'] ) Parent = NCMB::DataStore.new 'Parent' Child = NCMB::DataStore.new 'Child' child = Child.new(name: 'Taro') parent = Parent.new(name: 'Oya') parent.child = child parent.save
Version data entries
5 entries across 5 versions & 1 rubygems