Skip to content

Commit 9ce12be

Browse files
committed
Add plugin spec for Objects
1 parent 59b42e9 commit 9ce12be

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

textile/features.textile

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ jump_to:
2323
- Channels#realtime-channels
2424
- RealtimeChannel#realtime-channel
2525
- RealtimePresence#realtime-presence
26+
- Objects#objects
2627
- EventEmitter#eventemitter
2728
- Forwards compatibility#realtime-compatibility
2829
- State conditions and operations#state-conditions-and-operations
@@ -385,13 +386,15 @@ h3(#plugins). Plugins
385386
* @(PC2)@ No generic plugin interface is specified, and therefore there is no common API exposed by all plugins. However, for type-safety, the opaque interface @Plugin@ should be used in strongly-typed languages as the type of the @ClientOptions.plugins@ collection as per "TO3o":#TO3o.
386387
* @(PC3)@ A plugin provided with the @PluginType@ enum key value of @vcdiff@ should be capable of decoding "vcdiff"-encoded messages. It must implement the @VCDiffDecoder@ interface and the client library must be able to use it by casting it to this interface.
387388
** @(PC3a)@ The base argument of the @VCDiffDecoder.decode@ method should receive the stored base payload of the last message on a channel as specified by "RTL19":#RTL19. If the base payload is a string it should be encoded to binary using UTF-8 before being passed as base argument of the @VCDiffDecoder.decode@ method.
389+
* @(PC5)@ A plugin provided with the @PluginType@ enum key value of @Objects@ should provide the Objects feature functionality for realtime channels. It must implement the @ObjectsPlugin@ interface and the client library must be able to use it by casting it to this interface.
388390
* @(PC4)@ A client library is allowed to accept plugins other than those specified in this specification, through the use of additional @ClientOptions.plugins@ keys defined by that library. The library is responsible for defining the interface of these plugins, and for making sure that these keys do not clash with the keys defined in this specification.
389391

390392
h3(#plugin-type). PluginType
391393

392394
* @(PT1)@ @PluginType@ is an enum describing the different types of plugins that the library supports. See the @ClientOptions#plugins@ property ("TO3o":#TO3o).
393395
* @(PT2)@ @PluginType@ takes one of the following values:
394396
** @(PT2a)@ @vcdiff@ – see "PC3":#PC3.
397+
** @(PT2b)@ @Objects@ – see "PC5":#PC5.
395398

396399
h3(#vcdiff-decoder). VCDiffDecoder
397400

@@ -775,6 +778,8 @@ h3(#realtime-channel). RealtimeChannel
775778
** @(RTL8b)@ Unsubscribe with a name argument and a listener argument unsubscribes the provided listener if previously subscribed with a name-specific subscription
776779
* @(RTL9)@ @RealtimeChannel#presence@ attribute:
777780
** @(RTL9a)@ Returns the @RealtimePresence@ object for this channel
781+
* @(RTL27)@ @RealtimeChannel#objects@ attribute:
782+
** @(RTL27a)@ Returns the @Objects@ object for this channel "OBJ1":../objects-features#OBJ1
778783
* @(RTL10)@ @RealtimeChannel#history@ function:
779784
** @(RTL10a)@ Supports all the same params as @RestChannel#history@
780785
** @(RTL10b)@ Additionally supports the param @untilAttach@, which if true, will only retrieve messages prior to the moment that the channel was attached or emitted an @UPDATE@ indicating loss of continuity. This bound is specified by passing the querystring param @fromSerial@ with the @RealtimeChannel#properties.attachSerial@ assigned to the channel in the @ATTACHED@ @ProtocolMessage@ (see "RTL15a":#RTL15a). If the @untilAttach@ param is specified when the channel is not attached, it results in an error
@@ -2314,6 +2319,7 @@ class RealtimeChannel: // RTL*
23142319
state: ChannelState // RTL2b
23152320
whenState(ChannelState, (ChannelStateChange?) ->) // RTL25
23162321
presence: RealtimePresence // RTL9
2322+
objects: Objects // RTL27
23172323
properties: ChannelProperties // RTL15
23182324
// Only on platforms that support receiving push notifications:
23192325
push: PushChannel // RSH7
@@ -2853,6 +2859,7 @@ class Plugin // PC2
28532859

28542860
enum PluginType // PT*
28552861
"vcdiff" // PT2a
2862+
"Objects" // PT2b
28562863

28572864
class VCDiffDecoder // VD*
28582865
decode([byte] delta, [byte] base) -> [byte] // VD2a, PC3a

0 commit comments

Comments
 (0)