public final class ModuleContentTypes extends Object
| Modifier and Type | Class and Description |
|---|---|
class |
ModuleContentTypes.Async
Async module.
|
| Constructor and Description |
|---|
ModuleContentTypes(retrofit2.Retrofit retrofit,
Executor callbackExecutor) |
| Modifier and Type | Method and Description |
|---|---|
ModuleContentTypes.Async |
async() |
CMAContentType |
create(String spaceId,
CMAContentType contentType)
Create a new Content Type.
|
protected com.contentful.java.cma.ServiceContentTypes |
createService(retrofit2.Retrofit retrofit) |
String |
delete(String spaceId,
String contentTypeId)
Delete a Content Type.
|
CMAArray<CMAContentType> |
fetchAll(String spaceId)
Fetch all Content Types from a Space.
|
CMAArray<CMAContentType> |
fetchAll(String spaceId,
Map<String,String> query)
Fetch all Content Types from a Space with a query.
|
CMAContentType |
fetchOne(String spaceId,
String contentTypeId)
Fetch a Content Type with the given
contentTypeId from a Space. |
CMAContentType |
publish(CMAContentType contentType)
Publish a Content Type.
|
CMAContentType |
unPublish(CMAContentType contentType)
Un-Publish a Content Type.
|
CMAContentType |
update(CMAContentType contentType)
Update a Content Type.
|
public ModuleContentTypes(retrofit2.Retrofit retrofit,
Executor callbackExecutor)
protected com.contentful.java.cma.ServiceContentTypes createService(retrofit2.Retrofit retrofit)
public CMAContentType create(String spaceId, CMAContentType contentType)
contentType has an ID associated with it, that ID will be used,
otherwise the server will auto-generate an ID that will be contained in the response upon
success.spaceId - Space IDcontentType - Content TypeCMAContentType result instancepublic String delete(String spaceId, String contentTypeId)
spaceId - Space IDcontentTypeId - Content Type IDpublic CMAArray<CMAContentType> fetchAll(String spaceId)
spaceId - Space IDCMAArray result instancepublic CMAArray<CMAContentType> fetchAll(String spaceId, Map<String,String> query)
spaceId - Space IDquery - QueryCMAArray result instancepublic CMAContentType fetchOne(String spaceId, String contentTypeId)
contentTypeId from a Space.spaceId - Space IDcontentTypeId - Content Type IDCMAContentType result instancepublic CMAContentType publish(CMAContentType contentType)
contentType - Content TypeCMAContentType result instancepublic CMAContentType unPublish(CMAContentType contentType)
contentType - Content TypeCMAContentType result instancepublic CMAContentType update(CMAContentType contentType)
contentType - Content TypeCMAContentType result instancepublic ModuleContentTypes.Async async()
Copyright © 2016 Contentful, GmbH.. All Rights Reserved.