• No results found

3 Protocol Details

3.1 Server Details

3.1.4 Message Processing Events and Sequencing Rules

3.1.4.19 proc_CreateList

The proc_CreateList stored procedure is called to create a new entry in the content database for the specified list (1) and to return its metadata and full URL. The stored procedure is defined using T-SQL syntax, as follows: @bAlternateUrlOnCollision bit,

@Title nvarchar(255), @Version int,

@Author int, @BaseType int, @bCreateAttachmentsSubFolder bit,

@FeatureId uniqueidentifier,

@OnRestore bit,

@EventSinkAssembly nvarchar(255),-v_store @EventSinkClass nvarchar(255),

@EventSinkData nvarchar(255), @ContentTypes varbinary(max),

@RootFolderId uniqueidentifier = NULL, @TitleResource nvarchar(256) = NULL, @DescriptionResource nvarchar(256) = NULL, @ValidationFormula nvarchar(1024) = NULL, @ValidationMessage nvarchar(1024) = NULL, @FolderFullUrlRet nvarchar(256) = NULL OUTPUT, @TimeCreated datetime = NULL, @RequestGuid uniqueidentifier = NULL OUTPUT );

@SiteId: The site collection identifier of the site collection which contains the specified site (2).

@WebId: The site identifier of the site (2) which contains the specified list (1).

@ListId: The list identifier of the list (1) that is being created.

@DirName: The directory name of the list (1) location.

@FolderNameBase: A unique directory name used for the list (1).

@bAlternateUrlOnCollision: A bit that specifies whether or not to generate a unique alternate directory name specified by the @FolderNameBase parameter in the case of a name collision.

@Title: The title of the specified list (1).

@Version: The initial list (1) version to begin with.

@Author: The user identifier of the list (1) author.

@BaseType: This specifies the base type of the list (1). The value MUST be one of the following list (1) base types.

Value Description

0 Generic List

1 Document Library

3 Discussion Board

4 Survey List

5 Issues List

@bCreateAttachmentsSubFolder: A bit specifying whether or not to create a subfolder for list (1) attachments.

@FeatureId: The feature identifier of the feature associated with the list (1).

@ServerTemplate: The integer value of the list template that defines the base structure of this list (1).

@DocLibTemplate: The list template of the document library.

@ImageUrl: Contains the server-relative URL that points to an image associated with the list (1).

@SendToLocation: Contains an implementation-specific Send-To string holding a URL used for the list (1). If this parameter is NULL, it MUST be ignored.

@ReadSecurity: A value identifying the security policy for read access on list items. If value is set to 1, users with read permissions can read all list items. Otherwise, if this value is set to 2, users with read permissions can only read their own list items.

@WriteSecurity: A value identifying the security policy for write access on list items. The value MUST be in the following table.

Value Description

1 Users with write permissions have write access to all list items.

2 Users with write permissions have write access to their own list items only.

4 Users have no write access to any list items.

@Description: The text describing the list (1).

@MajorVersionCount: Sets the maximum number of major versions to be retained by the list (1).

@MinorVersionCount: Sets the maximum number of minor versions to be retained by the list (1).

@Fields: A version string followed by the XSD representation of the field definitions. The field definitions include display and interaction options. See [MS-WSSFO2] section 2.2.8.3.5.

@Direction: An enumerated value specifying the direction of text flow for user interface elements presented by this list (1). The value MUST be in the following table.

Value Description

0 No explicit direction is specified.

1 Text flow SHOULD be left to right.

2 Text flow SHOULD be right to left.

@Flags: A bit array for setting list (1) functionality. This parameter MUST not be NULL. Valid values are contained in the table defined in [MS-WSSFO2] section 2.2.2.5.

@ThumbnailSize: An integer used by lists (1) to determine the rendering size of an image thumbnail. If this parameter is NULL, it MUST be ignored.

@WebImageWidth: An integer used by lists (1) to determine the rendering width of an image. If this parameter is NULL, it MUST be ignored.

@WebImageHeight: An integer used by lists (1) to determine the rendering height of an image. If this parameter is NULL, it MUST be ignored.

@bParentFolderChecked: A bit that specifies whether or not the list (1) parent folder (the folder in which the list (1) is contained) has been checked for existence.

@OnRestore: A Boolean value indicating that this list (1) is undergoing a back-up restore operation.

@EventSinkAssembly: An assembly name for an event handler of an event sink for the list (1). If this parameter is NULL, it MUST be ignored.

@EventSinkClass: An assembly class identifier (CLSID) for an event handler of an event sink for the list (1). If this parameter is NULL, it MUST be ignored.

@EventSinkData: Event sink data for an event handler of an event sink for the list (1). If this parameter is NULL, it MUST be ignored.

@ContentTypes: The XSD representation of the content types available to this list (1).

@RootFolderId: The identifier (a GUID) of the root folder for this list (1).

@TitleResource: An optional Unicode string used to determine the list (1) title that is appropriate for a multilingual user interface (MUI). If this parameter is not NULL, it MUST be a resource token or the name of a user resource.

@DescriptionResource: An optional Unicode string used to determine the list (1) description that is appropriate for a MUI. If this parameter is not NULL, it MUST be a resource token or the name of a user resource.

@ValidationFormula: An optional Unicode string that can be used to perform custom validation rules prior to the list (1) being updated. If specified this MUST be an expression specified by [MS-WSSTS] section 2.9.

@ValidationMessage: An optional Unicode string, or strings, that are suitable to display in a user interface when the list (1) fails validation based on @ValidationFormula.

@FolderFullUrlRet: The full URL of the list (1).

@TimeCreated: The date and time the list (1) was created.

@RequestGuid: The optional request identifier for the current request.

Return values: The stored procedure returns an integer return code which MUST be in the following table.

Value Description

0 Successful execution.

3 The system cannot find the URL specified.

5 Access is denied.

80 The list (1) with the specified title already exists.

87 Invalid parameter specified (@SiteId, @WebId, @FolderNameBase).

212 The path segment is locked and cannot be reallocated.

1836 Not enough quota is available to process this command.

Result sets: The stored procedure MUST return 1 result set when the return code is zero ("0").

Otherwise, it MUST not return any result sets.

3.1.4.19.1 List Metadata Result Set

Returns the list (1) metadata for the newly created list (1). This result set will be returned when input parameter @BaseType has a value of 1. This result set is defined in the [MS-WSSFO2], section 2.2.5.12.

3.1.4.19.2 Id and Full URL Result Set

The Id and Full URL Result Set returns the list identifier and full URL of the new list (1). This result set will be returned when input parameter @BaseType has a value different than 1. The result set is defined using T-SQL syntax, as follows:

{ListId} uniqueidentifier, {FolderFullUrl} nvarchar(256);

{ListId}: Contains the list identifier of the list (1) that has been created.

{FolderFullUrl}: Contains the full URL of the list (1) that has been created.