Show/Hide Toolbars

TMS XData Documentation

Navigation: Design-Time Components

TXDataServer Component

Scroll Prev Top Next More

TXDataServer component wraps the TXDataServerModule module. Basically all properties in the component has a direct relation with the properties of the TXDataServerModule, in case of doubt refer to TXDataServerModule reference to learn more details about each property.

 

Properties

Name

Description

Pool: TXDataConnectionPool

Contains a reference to a TXDataConnectionPool component. This will be used as the connection pool for the XData server database operations.

ModelName: string

Specifies the name of the model to be used to create the TXDataServerModule instance.

DefaultExpandLevel: Integer

PutMode: TXDataPutMode

PostMode: TXDataPostMode

FlushMode: TXDataFlushMode

ProxyLoadDepth: Integer

ProxyListLoadDepth: Integer

SerializeInstanceRef: TInstanceRefSerialization

SerializeInstanceType: TInstanceTypeSerialization

UnknownMemberHandling: TUnknownMemberHandling

All those property values will be used to set the a property with same name in the TXDataServerModule instance when it's created. Refer to TXDataServerModule topic to learn the purpose of each property.

DefaultEntitySetPermissions: TEntitySetPermissions

Specifies the default permissions for all entity sets. By default no permissions are provided, which means entity publish will not be available. This is different behavior than when creating TXDataServerModule directly, since it automatically publishes all entities.

EntitySetPermissions: TEntitySetPermissionItems

A collection where you can specify entity set permissions for an entity set in particular. This will override the default entity set permissions.

property EnableEntityKeyAsSegment: Boolean

When True, it's possible to address single entities by using the URL format "/entityset/id" - in addition to the default "/entityset(id)". Default is False.

property SwaggerOptions: TXDataSwaggerOptions

property SwaggerUIOptions: TXDataSwaggerUIOptions

Provide access to configure Swagger and SwaggerUI behavior. See more information at OpenAPI/Swagger Support.

 

Events

Name

Description

OnModuleCreate: TXDataModuleEvent

 

Fired when the TXDataServerModule instance is created.

 

TXDataModuleEvent = procedure(Sender: TObject; Module: TXDataServerModule) of object;

 

Module parameter is the newly created TXDataServerModule instance.

OnGetPoolInterface: TGetPoolInterfaceEvent

Fired when the IDBConnectionPool interface is created by the TXDataConnectionPool component.

 

TGetPoolInterfaceEvent = procedure(Sender: TObject; var Pool: IDBConnectionPool) of object;

 

Pool parameter is the newly created IDBConnectionPool interface. You can override that value by creating your own interface and passing it in the Pool variable.

OnEntityInserting

OnEntityModifying

OnEntityDeleting

OnEntityGet

OnEntityList

OnModuleException

These are wrappers around the events described in the server-side events chapter. Please refer to that chapter to know more about the events and how to use them. Arguments (event-handler parameters) are exactly the same.