Beamable SDK
Public Member Functions | Public Attributes | Protected Member Functions | Properties | List of all members
Beamable.Content.ManifestSubscription Class Reference

This type defines part of the Beamable ContentObject system. More...

Inheritance diagram for Beamable.Content.ManifestSubscription:
Inheritance graph
[legend]
Collaboration diagram for Beamable.Content.ManifestSubscription:
Collaboration graph
[legend]

Public Member Functions

 ManifestSubscription (IDependencyProvider provider, string manifestID)
 
override PlatformSubscription< ClientManifestSubscribe (string scope, Action< ClientManifest > callback)
 This method is obsolete. The scope field won't do anything, and there is no support for subscribing to individual content type updates. You should simply use the variant of this method that doesn't accept the scope field. PlatformSubscribable<ScopedRsp,Data>.Subscribe() More...
 
bool TryGetContentId (string contentId, out ClientContentInfo clientInfo)
 Try to retrieve a ClientContentInfo from the current manifest, by content id. More...
 
Promise< ClientManifestGetManifest ()
 Get the latest ClientManifest that was received by the game client. This method will not start a network request. Instead, it will reference the most recent network request that is fetching the manifest. More...
 
Promise< ClientManifestGetManifest (ContentQuery query)
 
Promise< ClientManifestGetManifest (string filter)
 
- Public Member Functions inherited from Beamable.Api.PlatformSubscribable< ClientManifest, ClientManifest >
PlatformSubscription< Data > Subscribe (Action< Data > callback)
 Subscribe to the callback to receive fresh data when available. More...
 
virtual PlatformSubscription< Data > Subscribe (string scope, Action< Data > callback)
 Subscribe to the callback to receive fresh data when available. More...
 
Promise< UnitRefresh ()
 Manually refresh the available data. More...
 
Data GetLatest ()
 
Data GetLatest (string scope)
 
async Promise< ScopedRsp > Fetch (string scope="")
 Send a request and get the latest state of the subscription. This method will not trigger existing subscriptions More...
 
Promise< Data > GetCurrent (string scope="")
 Manually fetch the available data. If the server hasn't delivered a new update, this method will not return the absolute latest data unless you pass forceRefresh as true. More...
 
void Notify (Data data)
 Manually notify observing scopes regarding the available data. More...
 
void Notify (string scope, Data data)
 Manually notify observing scopes regarding the available data. More...
 

Public Attributes

Dictionary< Type, ContentCache_contentCaches = new Dictionary<Type, ContentCache>()
 This will be removed in a future release. Please do not use.
 

Protected Member Functions

override string CreateRefreshUrl (string scope)
 
override Promise< ClientManifestExecuteRequest (IBeamableRequester requester, string url)
 
override void OnRefresh (ClientManifest data)
 
- Protected Member Functions inherited from Beamable.Api.PlatformSubscribable< ClientManifest, ClientManifest >
 PlatformSubscribable (IDependencyProvider provider, string service, BeamableGetApiResource< ScopedRsp > getter=null)
 
virtual void Reset ()
 
Promise< UnitRefresh (string scope)
 Manually refresh the available data. More...
 
virtual Promise OnRefreshScope (string scope)
 
virtual Promise< ScopedRsp > ExecuteRequest (IBeamableRequester requester, string url)
 
virtual void OnRefresh (ScopedRsp data)
 
virtual Promise OnRefresh (ScopedRsp data, string[] scopes)
 
void ScheduleRefresh (long seconds, string scope)
 
void Unsubscribe (string scope, PlatformSubscription< Data > subscription)
 

Properties

string ManifestID = "global" [get]
 Every content manifest has an ID. Usually, a game will only have a single content manifest called "global", but it is possible to add more.
 
- Properties inherited from Beamable.Api.PlatformSubscribable< ClientManifest, ClientManifest >
bool UsesHierarchyScopes [getprotected set]
 

Additional Inherited Members

- Protected Attributes inherited from Beamable.Api.PlatformSubscribable< ClientManifest, ClientManifest >
IBeamableRequester requester
 
IConnectivityService connectivityService
 
INotificationService notificationService
 
CoroutineService coroutineService
 
IUserContext userContext
 
BeamableGetApiResource< ScopedRsp > getter
 
readonly string service
 

Detailed Description

This type defines part of the Beamable ContentObject system.

Related Links

img beamable-logo

Member Function Documentation

◆ CreateRefreshUrl()

override string Beamable.Content.ManifestSubscription.CreateRefreshUrl ( string  scope)
inlineprotectedvirtual

◆ GetManifest() [1/3]

Promise< ClientManifest > Beamable.Content.ManifestSubscription.GetManifest ( )
inline

Get the latest ClientManifest that was received by the game client. This method will not start a network request. Instead, it will reference the most recent network request that is fetching the manifest.

Returns
A Promise<ClientManifest> representing the network call.

◆ GetManifest() [2/3]

Promise< ClientManifest > Beamable.Content.ManifestSubscription.GetManifest ( ContentQuery  query)
inline

Parameters
queryA ContentQuery that will filter the resulting ClientManifest.entries field.
Returns
A Promise<ClientManifest> representing the network call.

◆ GetManifest() [3/3]

Promise< ClientManifest > Beamable.Content.ManifestSubscription.GetManifest ( string  filter)
inline

Parameters
filterA ContentQuery in string form that will filter the resulting ClientManifest.entries field
Returns
A Promise<ClientManifest> representing the network call.

◆ Subscribe()

override PlatformSubscription< ClientManifest > Beamable.Content.ManifestSubscription.Subscribe ( string  scope,
Action< ClientManifest callback 
)
inline

This method is obsolete. The scope field won't do anything, and there is no support for subscribing to individual content type updates. You should simply use the variant of this method that doesn't accept the scope field. PlatformSubscribable<ScopedRsp,Data>.Subscribe()

Parameters
scope
callback
Returns

◆ TryGetContentId()

bool Beamable.Content.ManifestSubscription.TryGetContentId ( string  contentId,
out ClientContentInfo  clientInfo 
)
inline

Try to retrieve a ClientContentInfo from the current manifest, by content id.

Parameters
contentIdA content ID
clientInfoAn out parameter for a ClientContentInfo that will be assigned the content associated with the contentId, or left null if the content ID isn't in the current manifest.
Returns
true if the content ID was found, false otherwise.

The documentation for this class was generated from the following file: