Class: RESTFramework::BaseSerializer
- Inherits:
-
Object
- Object
- RESTFramework::BaseSerializer
- Defined in:
- lib/rest_framework/serializers.rb
Direct Known Subclasses
Instance Method Summary collapse
-
#initialize(object: nil, controller: nil, **kwargs) ⇒ BaseSerializer
constructor
A new instance of BaseSerializer.
- #serialize ⇒ Object
Constructor Details
#initialize(object: nil, controller: nil, **kwargs) ⇒ BaseSerializer
Returns a new instance of BaseSerializer.
2 3 4 5 |
# File 'lib/rest_framework/serializers.rb', line 2 def initialize(object: nil, controller: nil, **kwargs) @object = object @controller = controller end |
Instance Method Details
#serialize ⇒ Object
7 8 9 |
# File 'lib/rest_framework/serializers.rb', line 7 def serialize raise NotImplementedError end |