Module: ActiveFedora::Core::ClassMethods

Extended by:
Deprecation
Defined in:
lib/active_fedora/core.rb

Instance Method Summary collapse

Instance Method Details

#generated_association_methodsObject



117
118
119
120
121
122
123
# File 'lib/active_fedora/core.rb', line 117

def generated_association_methods
  @generated_association_methods ||= begin
    mod = const_set(:GeneratedAssociationMethods, Module.new)
    include mod
    mod
  end
end

#to_class_uri(attrs = nil) ⇒ Object

Deprecated.

use to_rdf_representation instead

Returns a suitable string representation for :has_model



134
135
136
137
138
139
# File 'lib/active_fedora/core.rb', line 134

def to_class_uri(attrs = nil)
  if attrs
    Deprecation.warn ActiveFedora::Core, "to_class_uri no longer acceps an argument"
  end
  to_rdf_representation
end

#to_rdf_representationObject

Returns a suitable string representation for :has_model Override this method if you want to change how this class is represented in RDF.



128
129
130
# File 'lib/active_fedora/core.rb', line 128

def to_rdf_representation
  name
end