Component Programming Reference

From Virtual World Web Wiki
Jump to: navigation, search

Contents

This page is part of the Infrastructure Guide. Here we'll document the various interfaces available for building Virtual World Web server components. All of these interfaces live in the VWW.CoreLibs.ServerAPI assembly and namespace.

Layer One API

Remarks [edit]

The main set of interfaces used by components (Layer Two) to control the VWW server core software (Layer One).

IChatSystem (Full Article)

The chat system is a primary layer one interface. It provides methods for managing chat channels, and sending chat messages.

IComponentSystem (Full Article)

The component system is a primary layer one interface. It contains many useful utility methods for managing the component's lifetime, communicating with other components, communicating with root, and using the server transfer package system.

IEntitySystem (Full Article)

The entity system is a primary layer one interface. There are methods here for creating, managing and getting information about all kinds of Entities

IFinancialSystem (Full Article)

The financial system is a primary layer one interface. It provides methods for working with currencies and transactions.

IInventorySystem (Full Article)

The inventory system is a primary layer one interface. It provides methods for working with runtime inventory.

See also: IObjectSystem

IManagerFactory (Full Article)

An interface to the system-specific implementation of the Layer One Managers. Each system (Admin Web, Service Provider, Instance Host, Web View) provides its own implementation of the Layer One API which build on a set of base classes shared by all systems and which implemnt the Layer One API interfaces. Instances of these implmentations are created via a local implementation of the ManagerFactory class which is passed to the static LayerOne helper instance on startuup. In practise, components access Layer One through the LayerOne helper class

IObjectSystem (Full Article)

The object system is a primary layer one interface. It provides methods for working with Object Types, Object Templates and the Container System.

IPermissionSystem (Full Article)

The object system is a primary layer one interface. It provides methods for working with system permssions.

IResourceSystem (Full Article)

The object system is a primary layer one interface. It provides methods for managing resources and their metadata.

ISettingsSystem (Full Article)

The settings system is a primary layer one interface. It provides methods for getting and setting component settings as well as registering admin configurable settings and some helpful system properties.

ITranslationSystem (Full Article)

The translation system is a primary layer one interface. It provides methods for managing translation group subscriptions and local translation groups.

IUIScriptSystem (Full Article)

The UI script system is a primary layer one interface. It provides methods for working with UI scripts, sending them to clients, finding their instances, and releasing them.

IViewSystem (Full Article)

The view system is a primary layer one interface. It provides methods for working with DOM Views (server hosted DOM documents)

IWorldspaceSystem (Full Article)

The worldspace system is a primary layer one interface. It provides methods for working with Worldspace, Layouts and EditLayouts, and area groups

LayerOne (Full Article)

This is the main entry point to the server

The LayerOne static class is initialized by the system when it starts up and provides the gateway to the layer one API. The API surface is split up into chunks to keep it logically separated.

See also: Server API

See also: IManagerFactory


Layer Two Events

Remarks [edit]

The main set of interfaces that, when implementd by a component (Layer Two) will be called by the VWW server core software (Layer One) in response to various events.

IAbilityEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Ability events fire when connected users' UI or scripts "use" events.

See also: AbilityEventsHandler

IAdminLifetimeEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Admin lifetime events fire in the admin web component environment and offer service lifetime notifications.

See also: AdminLifetimeEventsHandler

IChatRuntimeEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Chat runtime events fire to offer components an opportunity to process user chat messages and offer slash command help.

See also: ChatRuntimeEventsHandler

IComponentEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Component events fire in the service provider component environment and offer component lifetime notifications.

See also: ProviderLifetimeEventsHandler

IEntityEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Entity events fire on the service provider in response to changes to Entities

See also: EntityEventsHandler

IFinancialEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Financial events fire on various systems to request components' help validating transactions, and to notify components of transactions' status

See also: FinancialEventsHandler

IHostLifetimeEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Host lifetime events fire in the instance host component environment and offer service lifetime notifications.

See also: HostLifetimeEventsHandler

IInstanceRuntimeEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Instance runtime events fire to inform the component of various events in a running instance, including instance lifetime events

See also: InstanceRuntimeEventsHandler

IInventoryEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Inventory events fire to notify components of activity in users' runtime inventory

See also: InventoryEventsHandler

ILoginEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Login events fire as the Authenticate instance host workflow runs. The IComponentActivity interface passed to each event allows you to pause or cancel the workflow so you can deliver UI.

See also: LoginEventsHandler

INavigateEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Navigate events fire as the Navigate instance host workflow runs. The IComponentActivity interface passed to each event allows you to pause or cancel the workflow so you can deliver UI.

See also: NavigateEventsHandler

INotificationEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Notification events form a powerful component communication infrastructure, and offer notifications about settings changes.

See also: NotificationEventsHandler

IObjectEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Provides events that Layer 2 components can use to responde to notifications of changes to [Container System|Containers], Object Types or Object Templates on either the service provider or instance host

See also: ObjectEventsHandler

IPermissionEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Permission events fire on the service provider to notify components of permission entry changes

See also: PermissionEventsHandler

IPersonaEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Persona events fire to inform components of relationship changes, and persona layout changes (mostly obsolete)

See also: PersonaEventsHandler

IPersonaSelectionEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Persona selection events fire as the Select Persona instance host workflow runs. The IComponentActivity interface passed to each event allows you to pause or cancel the workflow so you can deliver UI.

See also: PersonaSelectionEventsHandler

IProviderLifetimeEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Provider lifetime events fire in the service provider component environment and offer service lifetime notifications.

See also: ProviderLifetimeEventsHandler

IResourceEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Resource events fire when resources are created or changed

See also: ResourceEventsHandler

ISessionEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Session events fire on the service provider to notify components of session lifetime events

See also: SessionEventsHandler

IWebViewLifetimeEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Web view lifetime events fire in the web view component environment and offer service lifetime notifications.

See also: WebViewLifetimeEventsHandler

IWebViewPipelineEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Web View pipeline events fire to allow components to hook system account creation and intercept web requests

See also: WebViewPipelineEventsHandler

IWorldspaceEvents (Full Article)

This interface describes a Layer Two extensibility point. Components can implement this interface and an instance of the implementing class will be created by MEF on startup. Worldspace events fire on the service provider in response to changes to Worldspace

See also: AbilityEventsHandler


Layer One Exports

Remarks [edit]

IAbilityInfo (Full Article)

Information about an ability or ability group

See also: Ability System

IAbilitySet (Full Article)

An Ability Set represents the combined set abilities available to a Connection Identity (See also IConnectionIdentity). Abilities are organized as a hierarchy if ability groups with abilities which can be enabled or blocked at any level. Abilities can be presented by UI Scripts, and when "fired" can be responded to by components to carry out all sorts of operations.

See also: Ability System

See also: UI Scripting

IAccountInfo (Full Article)

An interface to a structure of information about a persona which is a type of Entity

IAreaGroupInfo (Full Article)

An interface to a structure of information about an area group which is a type of Worldspace

IAreaInfo (Full Article)

An interface to a structure of information about an area (any part of Worldspace).

IBuildLocationInfo (Full Article)

A writable location info interface, used during navigation to modify target locations

IChatChannelExtended (Full Article)

An interface to a ChatChannelExtended javascript object. These will only be passed in to Layer Two methods that are offered to the JavaScript environment, and would be dangerous to access outside of one of those calls which always happen in the context of a JavaScript Isolate thread

IClientConnection (Full Article)

Represents a client connection.

IComponentActivity (Full Article)

Represents a component's role in a user workflow. There are two workflows: Authenticate, and Navigate. These workflows are complex and have many steps. You may want to respond to various events (steps) along a workflow by pausing the workflow to communicate with an outside service, or to present the user with interstitial UI (like an ad, poll, billing interface, etc). Many of the events in ILoginEvents, INavigateEvents, and IPersonaSelectionEvents offer this object which can be used to accomplish this Call RegisterPendingOperation to pause the workflow. Call CompletePendingOperation later to resume it. You can call SetReturnValue if an event is requesting something from L2. You can set Cancelled and ErrorMessage if you want to report a problem and cancel the workflow.

IComponentInfo (Full Article)

Information about a component (plugin) installed on the server

IConfirmationHandle (Full Article)

Represents a confirmation request in progress with a client

IConnectionIdentity (Full Article)

Represents a user connected to the system and a Connection Identity from the Instance Host's point of view. Provides identity details (entity memberships), current location and Participant, and provides access to many other Layer One objects related to the connection.

IConnectionIdentityBase (Full Article)

Represents the base of an IConnectionIdentity or ISessionManager

ICurrencyInfo (Full Article)

Information about an installed Financial System currency

IDOMControllerExtended (Full Article)

An interface to a DOMControllerExtended javascript object. These will only be passed in to Layer Two methods that are offered to the JavaScript environment, and would be dangerous to access outside of one of those calls which always happen in the context of a JavaScript Isolate thread

IDOMGeometryExtended (Full Article)

An interface to a DOMGeometryExtended javascript object. These will only be passed in to Layer Two methods that are offered to the JavaScript environment, and would be dangerous to access outside of one of those calls which always happen in the context of a JavaScript Isolate thread

IDOMObjectExtended (Full Article)

An interface to a DOMObjectExtended javascript object. These will only be passed in to Layer Two methods that are offered to the JavaScript environment, and would be dangerous to access outside of one of those calls which always happen in the context of a JavaScript Isolate thread

IDOMRenderableExtended (Full Article)

An interface to a DOMRenderableExtended javascript object. These will only be passed in to Layer Two methods that are offered to the JavaScript environment, and would be dangerous to access outside of one of those calls which always happen in the context of a JavaScript Isolate thread

IDOMTransformExtended (Full Article)

An interface to a DOMTransformExtended javascript object. These will only be passed in to Layer Two methods that are offered to the JavaScript environment, and would be dangerous to access outside of one of those calls which always happen in the context of a JavaScript Isolate thread

IDynamicGroupInfo (Full Article)

An interface to a structure of information about a dynamic group which is a type of Entity. Connections can be added to dynamic group entities at runtime by components.

IEntityEntry (Full Article)

Information about a single entity currently represented by an IConnectionIdentity

IEntityGroupInfo (Full Article)

An interface to a structure of information about an entity group which is a type of Entity

IEntityInfo (Full Article)

An interface to a structure of information about an Entity (the base for all Entities)

IExperienceData (Full Article)

A collection of experience metrics for an IConnectionIdentity

IExperienceMetric (Full Article)

Information about a specific experience metric associated with an IConnectionIdentity

IIdentityBase (Full Article)

The base of an identity of any kind. Provides basic information about the account, persona, and group memberships of the identity.

IInstanceContext (Full Article)

Represnets a running instance on an Instance Host

IInstanceExtended (Full Article)

An interface to a InstanceGlobals javascript object. These will only be passed in to Layer Two methods that are offered to the JavaScript environment, and would be dangerous to access outside of one of those calls which always happen in the context of a JavaScript Isolate thread

IInstanceInfo (Full Article)

Base information about a running instance, available on both the service provider and instance host

IInstanceMember (Full Article)

Information about a member of an instance, that may or may not be an IParticipant

IInteractionMapping (Full Article)

Represents an interaction mapping registered on an IViewInfo. An interaction mapping connects an IViewAbility to a set of DOM nodes via a CSS-like Selector making the ability into an interaction that can be "triggered on" the selected objects.

IInteractionMappingExtended (Full Article)

An interface to a InteractionMappingExtended javascript object. These will only be passed in to Layer Two methods that are offered to the JavaScript environment, and would be dangerous to access outside of one of those calls which always happen in the context of a JavaScript Isolate thread

IInventoryItemWrapper (Full Article)

Read-only information about a live inventory item

IJSServerBridge (Full Article)

Represents a running server javascript context

ILayerInfo (Full Article)

An interface to a structure of information about a layer. Layers are DOM documents stored in ObjectTypes that make up the objects you see in a scene.

ILayerVersionEditSession (Full Article)

Represents an active layer editing session for a version of a layer

ILayerVersionInfo (Full Article)

An interface to a structure of information about a layer version. Layers are DOM documents stored in ObjectTypes that make up the objects you see in a scene.

ILinkedServerInfo (Full Article)

Information about a partner service provider that we have write access to. Used to initiate server to server transfers.

ILocationInfo (Full Article)

Describes a VWW location

INeedAccountResolve (Full Article)

Used when asking components to resolve an entity to an appropriate financial system account for a given currency.

INeighborInfo (Full Article)

Information about instances of the same scene currently running on a service provider

IObjectContainerInfo (Full Article)

An interface to a structure of information about an Object Container

IObjectTemplateInfo (Full Article)

An interface to a structure of information about an Object Template

IObjectTemplateTransaction (Full Article)

Represents an Object Template creation, deletion, or transfer in progress

IParticipant (Full Article)

Information about a member of an instance that is fully embodied (has an avatar)

IParticipantExtended (Full Article)

An interface to a ParticipantExtended javascript object. These will only be passed in to Layer Two methods that are offered to the JavaScript environment, and would be dangerous to access outside of one of those calls which always happen in the context of a JavaScript Isolate thread

IPermissionInfo (Full Article)

Information about a system permission entry

IPersonaInfo (Full Article)

An interface to a structure of information about a persona which is a type of Entity

IResourceItemFileInfo (Full Article)

Information about a resource item physical file

IResourceItemInfo (Full Article)

Information about a resource item

IResourceTypeInfo (Full Article)

Information about a system resource type

IRuntimeLayer (Full Article)

An interface to a structure of information about a runtime layer in an instance

ISceneInfo (Full Article)

An interface to a structure of information about a scene which is a type of Worldspace

ISceneTypeInfo (Full Article)

An interface to a structure of information about a scene type

ISecurableInfo (Full Article)

An interface to a structure of information about a Securable (the base for all Worldspace and Entities)

ISessionManager (Full Article)

Represents a user connection from the service provider's point of view.

IStartPointInfo (Full Article)

Information about an available startpoint in an instance

ITransaction (Full Article)

Represents a financial system transaction

ITransactionInfo (Full Article)

Used when resolving accounts for a transaction source

ITransactionReport (Full Article)

A collection of information about financial system transactions

ITransactionReportItem (Full Article)

Represents a single financial system transaction

ITransactionReportTarget (Full Article)

Information about a transaction target (payee)

ITransactionTargetInfo (Full Article)

Used when resolving accounts for transaction targets

ITransferItem (Full Article)

Used when packing transfer package data to allow Layer Two components identify dependancies

IValidationContext (Full Article)

Represents the Instance or ConnectionIdentity's currently visible ObjectContainers

IViewAbility (Full Article)

Information about a runtime ability defined in a view (running instance). See IViewInfo.

IViewInfo (Full Article)

Information about a server hosted view. A view is a piece of DOM that connected users receive updates about, and which can host scripts, custom abilities, interactions, etc. A running instance is one type of view. Components can also create views for things like avatar customization, object previews, etc.

IViewMember (Full Article)

Information about a view member. This represents a connection's presence in a shared DOM view.

See also: Ability System

IVirtualIdentity (Full Article)

Represents a virtual connection identity which can be used to test area permissions that a specific user would have in an area

IWorldInfo (Full Article)

An interface to a structure of information about a world which is a type of Worldspace

OnInteractionEventArgs (Full Article)

information about an interaction being fired / used (see IViewInfo IInteractionMapping IViewAbility)

TargetChangedEventArgs (Full Article)

Information about a TargetChanged event on an InstanceMember


Layer One Enums

Remarks [edit]

AvatarBuildTarget (Full Article)

Selects a known named avatar view

LayoutLoaderMode (Full Article)

Selects a mode for DOM deserialization

LocalApplicationType (Full Article)

Specifies the type of a registered local (layer 1) application with core api access

SettingDataType (Full Article)

Used when registering user-configurable settings to specify a data type to imrpove Admin UI handling

TemplateTransactionState (Full Article)

The status of an Object Template Transaction

TransactionAuthResult (Full Article)

Specifies the result of a Financial System transaction authorization attempt

TransactionStatus (Full Article)

The status of a Financial System transaction

TransferItemType (Full Article)

Specifies the type of the Layer One object ID

ViewTarget (Full Article)

Used when specifying the parts of an instance DOM a user should have access to

WorkflowStep (Full Article)

Lists the authenticate or navigate steps at which a workflow could be paused


Server API Utility

Remarks [edit]

VWWComponentAttribute (Full Article)

Must be set at the assembly level to mark your assembly as a VWW Component.


Layer Two Event Handler Stubs

Remarks [edit]

A set of stubbed implementations of the Layer Two Events interfaces as virtual methods to make overriding and implementing single events much friendlier.

AbilityEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IAbilityEvents

AdminLifetimeEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IAdminLifetimeEvents

ChatRuntimeEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IChatRuntimeEvents

EntityEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IEntityEvents

FinancialEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IFinancialEvents

HostLifetimeEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IHostLifetimeEvents

InstanceRuntimeEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IInstanceRuntimeEvents

InventoryEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IInventoryEvents

LoginEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: ILoginEvents

NavigateEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: INavigateEvents

NotificationEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: INotificationEvents

ObjectEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IObjectEvents

PermissionEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IPermissionEvents

PersonaEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IPersonaEvents

PersonaSelectionEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IPersonaSelectionEvents

ProviderLifetimeEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IProviderLifetimeEvents

See also: IComponentEvents

ResourceEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IResourceEvents

SessionEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: ISessionEvents

WebViewLifetimeEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IWebViewLifetimeEvents

WebViewPipelineEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IWebViewPipelineEvents

WorldspaceEventsHandler (Full Article)

This class implements a Layer Two extensibility point as virtual members which can be overriden as needed. Derive from this class to provide your own implementation.

See also: IWorldspaceEvents


UI Script Handlers

Remarks [edit]

Some types to help implement UI script callback handlers. These handlers form the server side of UI Scripts.

IJavaScriptCallbackContext (Full Article)

When a message is received from a connected client UI script, this context is passed to your handler's Callback method if the reflection based proxy system isn't able to automatically map the message to one of your handler methods. It represents a deserialized JSON message with the properties of the root object exposed as a collection.

IUIScript (Full Article)

All Component UI Script handlers must implement this interface, provide a constructor that takes an IUIScriptHandle, and should have a UIScriptHandlerAttribute applied

IUIScriptHandle (Full Article)

Represents a Layer One UI script handle.

ScriptHandler (Full Article)

Provides a default implementation of IUIScript which you can derive from

UIScriptHandlerAttribute (Full Article)

Marks a class as a UI Script Handler