WEB_STORAGE_OBJECT Structure  
 

The WEB_STORAGE_OBJECT structure contains information about an individual storage object.

typedef struct _WEB_STORAGE_OBJECT
{
    TCHAR      szObjectId[64];
    TCHAR      szLabel[512];
    TCHAR      szDigest[128];
    TCHAR      szContent[128];
    DWORD      dwAttributes;
    DWORD      dwObjectSize;
    SYSTEMTIME stCreated;
    SYSTEMTIME stModified;
} WEB_STORAGE_OBJECT, *WEB_STORAGE_OBJECT;

Members

szObjectId
A null-terminated string which contains the unique identifier associated with this object. Object IDs are guaranteed to be unique for each storage object that is created by the application. The maximum length of an object ID is 64 characters, including the terminating null character.
szLabel
A null-terminated string which contains the label assigned to the object by the application. Object labels are case-sensitive and must be unique for each object. An application uses labels to reference an object with a human-recognizable name, rather than referencing them by their object ID. The maximum length of an object label is 512 characters, including the terminating null character.
szDigest
A null-terminated string which specifies the digest of the object contents, computed using an SHA-256 hash. The maximum length of the szDigest string is 128 characters, including the terminating null character. However, the digest value is always represented as a string of hexadecimal numbers that is exactly 64 characters long. It is important to note that even a zero-length object will have a digest, which is the standard SHA-256 NULL hash value.
szContent
A null-terminated string which specifies the MIME content type for the storage object. The content type is determined by the object label and evaluating the contents of the object. It is also possible for the application to explicitly specify the content type of the object when it is created.
dwAttributes
An unsigned integer value that specifies the attributes for the storage object. The object attributes are comprised of one or more bitflags:
Value Constant Description
0 WEB_OBJECT_DEFAULT Default object attributes. This value is used to indicate the object can be modified, or that the attributes for a previously existing object should not be changed.
1 WEB_OBJECT_NORMAL A normal object that that can be read and modified by the application. This is the default attribute for new objects that are created by the application.
2 WEB_OBJECT_READONLY A read-only object that can only be read by the application. Attempts to modify or replace the contents of the object will fail. Read-only objects can be deleted.
4 WEB_OBJECT_HIDDEN A hidden object. Objects with this attribute are not returned when enumerated using the EnumObjects method. The object can only be accessed directly when specifying its label.
dwObjectSize
An unsigned integer value that specifies the size of the storage object in bytes. The maximum size of an individual object is determined by the storage quota limits established for the account.
stCreated
A SYSTEMTIME structure that specifies the date and time the storage object was created. This value is represented using Coordinated Universal Time (UTC) and is not adjusted for the local time zone.
stModified
A SYSTEMTIME structure that specifies the date and time the storage object was last modified. This value is represented using Coordinated Universal Time (UTC) and is not adjusted for the local time zone. When a storage object is first created, this value will be the same as the object creation time.

Remarks

The object content type will always be in the format type/subtype where the type specifies a common media type (e.g.: text, audio, video, etc.) and subtype specifies the specific content. The most common content type for text files is text/plain. If the content type is unknown, the default content type is application/octet-stream.

Text objects may also optionally include the character encoding as part of the content type. For example, if an object contains UTF-8 encoded text, the content type may be returned as text/plain; charset=utf-8. If your application is parsing the content types, you must check if a character encoding was also included in the value. Text objects that do not specify an encoding either contain ASCII or text which uses the system code page. Unicode text will always be stored using UTF-8 encoding.

To adjust the object creation and modification times to account for the local time zone, use the SystemTimeToTzSpecificLocalTime method. If you prefer to use FILETIME values, use the SystemTimeToFileTime method.

Requirements

Minimum Desktop Platform: Windows 7 (Service Pack 1)
Minimum Server Platform: Windows Server 2008 R2 (Service Pack 1)
Header: Include cstools10.h
Unicode: Implemented as Unicode and ANSI versions.