lib/ripple/associations.rb in ripple-0.9.0 vs lib/ripple/associations.rb in ripple-0.9.2

- old
+ new

@@ -9,12 +9,26 @@ # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. -require 'ripple' +require 'active_support/concern' +require 'riak/walk_spec' +require 'ripple/translation' +require 'ripple/associations/proxy' +require 'ripple/associations/instantiators' +require 'ripple/associations/linked' +require 'ripple/associations/embedded' +require 'ripple/associations/many' +require 'ripple/associations/one' +require 'ripple/associations/linked' +require 'ripple/associations/one_embedded_proxy' +require 'ripple/associations/many_embedded_proxy' +require 'ripple/associations/one_linked_proxy' +require 'ripple/associations/many_linked_proxy' + module Ripple # Adds associations via links and embedding to {Ripple::Document} # models. Examples: # # # Documents can contain embedded documents, and link to other standalone documents @@ -46,21 +60,9 @@ # person.friends << Person.find("seancribbs") # Links to people/seancribbs with tag "friend" # person.addresses << Address.new(:street => "100 Main Street") # Adds an embedded address # person.account.paid_until = 3.months.from_now module Associations extend ActiveSupport::Concern - extend ActiveSupport::Autoload - - autoload :Proxy - autoload :One - autoload :Many - autoload :Embedded - autoload :Linked - autoload :Instantiators - autoload :OneEmbeddedProxy - autoload :ManyEmbeddedProxy - autoload :OneLinkedProxy - autoload :ManyLinkedProxy module ClassMethods # @private def inherited(subclass) super