Class: Contentful::Management::EditorInterface
- Inherits:
-
Object
- Object
- Contentful::Management::EditorInterface
- Defined in:
- lib/contentful/management/editor_interface.rb
Overview
Resource class for Editor Interface.
Instance Attribute Summary
Attributes included from Resource::SystemProperties
Attributes included from Resource
#client, #properties, #raw_object, #request
Class Method Summary collapse
-
.create ⇒ Object
Creates an EditorInterface.
-
.default(client, space_id, environment_id, content_type_id) ⇒ Contentful::Management::EditorInterface
Gets the Default Editor Interface.
-
.find ⇒ Object
Finds an EditorInterface.
Instance Method Summary collapse
-
#destroy ⇒ Object
Destroys an EditorInterface.
-
#update(attributes) ⇒ Contentful::Management::EditorInterface
Updates an Editor Interface.
Methods included from Resource::EnvironmentAware
Methods included from Resource::Refresher
Methods included from Resource
#array?, #default_locale, #environment_id, #fields, #nested_locale_fields?, #resource?, #save, #sys
Class Method Details
.create ⇒ Object
Creates an EditorInterface.
Not Supported
36 37 38 |
# File 'lib/contentful/management/editor_interface.rb', line 36 def self.create(*) fail 'Not supported' end |
.default(client, space_id, environment_id, content_type_id) ⇒ Contentful::Management::EditorInterface
Gets the Default Editor Interface
22 23 24 |
# File 'lib/contentful/management/editor_interface.rb', line 22 def self.default(client, space_id, environment_id, content_type_id) ClientEditorInterfaceMethodsFactory.new(client, space_id, environment_id, content_type_id).default end |
.find ⇒ Object
Finds an EditorInterface.
Not Supported
29 30 31 |
# File 'lib/contentful/management/editor_interface.rb', line 29 def self.find(*) fail 'Not supported' end |
Instance Method Details
#destroy ⇒ Object
Destroys an EditorInterface.
Not Supported
77 78 79 |
# File 'lib/contentful/management/editor_interface.rb', line 77 def destroy fail 'Not supported' end |
#update(attributes) ⇒ Contentful::Management::EditorInterface
Updates an Editor Interface
60 61 62 63 64 65 66 67 68 69 70 71 72 |
# File 'lib/contentful/management/editor_interface.rb', line 60 def update(attributes) ResourceRequester.new(client, self.class).update( self, { space_id: space.id, environment_id: environment_id, content_type_id: content_type.id, editor_id: id }, { 'controls' => attributes[:controls] || controls }, version: sys[:version] ) end |