Micro Focus Content Manager SDK 10.1
TRIM.SDK.InputDocument Class Reference

A helper class that encapsulates a document that is to be attached to a TRIM object. More...

Inheritance diagram for TRIM.SDK.InputDocument:
TRIM.SDK.TrimSDKObject

Public Member Functions

 InputDocument ()
 Constructs an input document. More...
 
 InputDocument (string fileName)
 Constructs an input document based on the nominated operating system file name. More...
 
 InputDocument (string emailSubject, string emailContent, TrimDateTime sentDate, TrimDateTime receivedDate, bool timesAreUniversal)
 Constructs an input document based on an email message. More...
 
 InputDocument (ElectronicStore alreadyInStore, string alreadyInStoreID, long alreadyInStoreBytes, string alreadyInStoreExtension, TrimDateTime alreadyInStoreDateModified)
 Constructs an input document corresponding to a pre-existing item in an external store. Note that this does not allow multiple references to a single stored item - TRIM does not support single instancing in this way. More...
 
 InputDocument (ElectronicStore alreadyInStore, string alreadyInStoreID, long alreadyInStoreBytes, string alreadyInStoreExtension)
 Constructs an input document corresponding to a pre-existing item in an external store. Note that this form of the constructor is obsolete, please use the one that supplies DateModified as an extra parameter. More...
 
 InputDocument (OfflineRecord offlineRecordToSetAs, bool updateAfterCheckIn)
 Constructs an input document corresponding to an item in the TRIM offline records folder. More...
 
void AddAttachment (string inputFile, string displayName)
 Adds the nominated file as an attachment of the mail message of this Input Document, if it is a mail message. More...
 
void AddAttachment (EmailAttachment attachedItem)
 Adds the attachment object as an attachment of the mail message of this Input Document, More...
 
EmailAttachmentList GetAttachments ()
 Gets all the attachments associated with this InputDocument More...
 
void AddRecipient (MailRecipientType RecipientType, string mailAddress, string displayName, string mailType)
 Adds the person described by the nominated email address and display name to the 'To', 'Cc' or 'Bcc' field of the mail message, if this InputDocument is a mail message. More...
 
void AddRecipient (MailRecipientType recipientType, EmailParticipant mailRecipient)
 Adds the person described by the EmailParticipant object to the 'To' , 'Cc' or 'Bcc' field of the mail message, if this InputDocument is a mail message. More...
 
EmailParticipantList GetRecipients (MailRecipientType recipientType)
 Gets the author iof this email message as an EmailParticipant object More...
 
void SetAuthor (string mailAddress, string displayName, string mailType)
 Sets the person described by the nominated email address and display name as the Author of the mail message, if this InputDocument is a mail message. More...
 
void SetAuthor (EmailParticipant newAuthor)
 Sets the person described by the nominated EmailParticipant as the Author of the mail message, if this InputDocument is a mail message. More...
 
EmailParticipant GetAuthor ()
 Gets the author iof this email message as an EmailParticipant object More...
 
void CleanupMailFiles ()
 Removes all attachment and native mail message files, as well as any temporary file associated with this InputDocument from the hard disk. More...
 
void SetAsFile (string fileName)
 Sets the Input Document to correspond to the document at the nominated file path More...
 
void SetAsMailMessage (string subject, string content, TrimDateTime sent, TrimDateTime received)
 Sets the Input Document to be of a TRIM mail message format (a .vmbx file). The supplied parameters should match the original email message fields and will be used in this Input Document object. More...
 
void SetAsMailMessage ()
 Sets the Input Document to be of a TRIM mail message format (a .vmbx file). The various fields of the original email message should be copied to the corresponding fields on this Input Document object. More...
 
void SetAsAlreadyStoredItem (ElectronicStore alreadyInStore, string alreadyInStoreID, long alreadyInStoreBytes, string alreadyInStoreExtension, TrimDateTime alreadyInStoreDateModified)
 Sets the Input Document to correspond to a document that has already been stored in a TRIM document store. Note that this does not allow multiple references to a single stored item - TRIM does not support single instancing in this way. More...
 
void SetAsAlreadyStoredItem (ElectronicStore alreadyInStore, string alreadyInStoreID, long alreadyInStoreBytes, string alreadyInStoreExtension)
 Sets the Input Document to correspond to a document that has already been stored in a TRIM document store. Note that this form of the constructor is obsolete, please use the one that supplies DateModified as an extra parameter More...
 
void SetAsManageInPlaceItem (ElectronicStore mipStore, string externalId, long xdocBytes, string xdocExtension, TrimDateTime xdocDateModified)
 Sets the Input Document to correspond to an item in an document storage system that is to be managed "in place". The externalId property will be used by Content Manager to provide a view of the document with the Content Manager user interface. The format of the externalId will be suitable for the type of Manage In Place store. For Windows File System, it is the path to the document (preferable UNC path). More...
 
void SetAsOfflineRecord (OfflineRecord offlineRecordToSetAs, bool UpdateAfterCheckIn)
 Sets the InputDocument from an Offline Record More...
 
void SetAsOneDriveDocument (string fileName, string oneDriveDriveId, string oneDriveItemId, string oneDriveCTag)
 Sets the Input Document to be based on an OneDrive document. A record created from this InputDocument will be presumed to spend most of its lifecycle in OneDrive, relying on Microsoft functionality for such things as Checking out, sharing, etc Once the record has been created, you can access the OneDrive using the ExternalEditorId property, which will be look like DriveId/items/DriveItemId, eg b!UgiVBAllpkmHZy1DJVGavKL4VWza519CgBB5T4uRNiClblKr8Q-XQpi4vzQ1_eEt/items/01NBX3FBPHWTXGMIKRZZHIC2R7QCNELYV6 More...
 
- Public Member Functions inherited from TRIM.SDK.TrimSDKObject
 TrimSDKObject ()
 

Properties

string Name [get]
 Gets a string containing a descriptive title for this InputDocument object. More...
 
bool IsMailMessage [get]
 Gets a Boolean value indicating whether this InputDocument is a mail message More...
 
bool TimesAreUniversal [get, set]
 Gets or sets a Boolean value indicating whether the times of the 'SentDate' and 'ReceivedDate' properties of this InputDocument are based on Universal Time Coordinates / Greenwich Mean Time. More...
 
string Subject [get, set]
 Gets or sets a string containing the subject of the mail message, if this InputDocument is a mail message. More...
 
string MessageId [get, set]
 Gets or sets a string containing the unique message id of the mail message, if this InputDocument is a mail message. More...
 
string ConversationId [get, set]
 Gets or sets a string containing the conversation id of the mail message, if this InputDocument is a mail message. More...
 
string MimeType [get, set]
 Gets or sets a string containing the mime type of the input document.
More...
 
string Content [get, set]
 Gets or sets a string containing the body (main content) of the mail message, if this InputDocument is a mail message More...
 
TrimDateTime SentDate [get, set]
 Gets or sets the date the mail message was sent, if this InputDocument is a mail message More...
 
TrimDateTime ReceivedDate [get, set]
 Gets or sets the date this mail message was received, if this InputDocument is a mail message More...
 
string NativeMailFile [get, set]
 Gets or sets a string containing the file path to the native mail file for this mail message, if this InputDocument is a mail message. More...
 
bool HasAttachments [get, set]
 Gets or sets a boolean value indicating whether the email message has attachments. If you are passing a native email file such as .msg or .eml, this allows you to indicate the email has attachments without having to extract them and pass them into AddAttachment More...
 
bool IsExternalStoreItem [get]
 
string ExternalStoreId [get]
 No longer used. More...
 
string ExternalExtension [get]
 No longer used. More...
 
bool IsAlreadyInStore [get]
 Gets a boolean value indicating whether this inputDocument represents an item that has already stored in a TRIM document store. Note that this does not allow multiple references to a single item - TRIM does not support single instancing in this way. More...
 
TrimURI AlreadyInStoreUri [get]
 Gets a Int64 value indicating the URI of the store that this input document is already stored in. Only relevant if IsAlreadyInStore is true. More...
 
string AlreadyInStoreID [get]
 Gets a String value indicating the store ID that this input document is already stored as. Only relevant if IsAlreadyInStore is true. More...
 
string AlreadyInStoreExtension [get]
 Gets a String value indicating the extension of an "already stored" item. Only relevant if IsAlreadyInStore is true. More...
 
long AlreadyInStoreSize [get]
 Gets an Int64 value indicating the size (in bytes) of an "already stored" item. Only relevant if IsAlreadyInStore is true. More...
 
TrimDateTime AlreadyInStoreDateModified [get]
 Gets a datetime value indicating the date last modified of an "already stored" item. Only relevant if IsAlreadyInStore is true. More...
 
OfflineRecord OfflineRecord [get]
 Gets the Offline Record object associated with this document. More...
 
bool IsOfflineRecord [get]
 Gets a boolean value indicating whether this document is an Offline Record. More...
 
string CheckinAs [get, set]
 Gets or sets a string containing the checkin path as it is to be remembered in Content Manager More...
 
bool UpdateOfflineRecord [get]
 Gets a Boolean value indicating whether the offline record should be updated or removed as part of the check in process More...
 
string LocalFile [get]
 Gets a string containing the path to the document corresponding to this Input Document. If this InputDocument is a mail message, this is the path to the .vmbx file created through this InputDocument object. More...
 
string ContentId [get, set]
 Gets or sets a string containing a unique hash of the content of this document ( such as a OneDrive CTag). More...
 
string VerificationHash [get, set]
 Gets or sets a 64-byte MD5 hash of the document that can be used for end to end verification. When the document is submitted to the record this hash will be checked for validity, allowing an end-to-end verification mechanism to be established. For compatibility, you can calculated this hash using the Database.CalculateDocumentHash function. More...
 
- Properties inherited from TRIM.SDK.TrimSDKObject
string ErrorMessage [get]
 All TRIM SDK objects have an ErrorMessage property which can be used to examine any error that may have occurred in the most recent method call. More...
 
TrimException Error [get]
 All TRIM SDK objects have an Error property which can be used to examine any error that may have occurred in the most recent method call. More...
 

Detailed Description

A helper class that encapsulates a document that is to be attached to a TRIM object.

Constructor & Destructor Documentation

◆ InputDocument() [1/6]

TRIM.SDK.InputDocument.InputDocument ( )

Constructs an input document.

◆ InputDocument() [2/6]

TRIM.SDK.InputDocument.InputDocument ( string  fileName)

Constructs an input document based on the nominated operating system file name.

◆ InputDocument() [3/6]

TRIM.SDK.InputDocument.InputDocument ( string  emailSubject,
string  emailContent,
TrimDateTime  sentDate,
TrimDateTime  receivedDate,
bool  timesAreUniversal 
)

Constructs an input document based on an email message.

◆ InputDocument() [4/6]

TRIM.SDK.InputDocument.InputDocument ( ElectronicStore  alreadyInStore,
string  alreadyInStoreID,
long  alreadyInStoreBytes,
string  alreadyInStoreExtension,
TrimDateTime  alreadyInStoreDateModified 
)

Constructs an input document corresponding to a pre-existing item in an external store. Note that this does not allow multiple references to a single stored item - TRIM does not support single instancing in this way.

◆ InputDocument() [5/6]

TRIM.SDK.InputDocument.InputDocument ( ElectronicStore  alreadyInStore,
string  alreadyInStoreID,
long  alreadyInStoreBytes,
string  alreadyInStoreExtension 
)

Constructs an input document corresponding to a pre-existing item in an external store. Note that this form of the constructor is obsolete, please use the one that supplies DateModified as an extra parameter.

◆ InputDocument() [6/6]

TRIM.SDK.InputDocument.InputDocument ( OfflineRecord  offlineRecordToSetAs,
bool  updateAfterCheckIn 
)

Constructs an input document corresponding to an item in the TRIM offline records folder.

Member Function Documentation

◆ AddAttachment() [1/2]

void TRIM.SDK.InputDocument.AddAttachment ( EmailAttachment  attachedItem)

Adds the attachment object as an attachment of the mail message of this Input Document,

◆ AddAttachment() [2/2]

void TRIM.SDK.InputDocument.AddAttachment ( string  inputFile,
string  displayName 
)

Adds the nominated file as an attachment of the mail message of this Input Document, if it is a mail message.

◆ AddRecipient() [1/2]

void TRIM.SDK.InputDocument.AddRecipient ( MailRecipientType  recipientType,
EmailParticipant  mailRecipient 
)

Adds the person described by the EmailParticipant object to the 'To' , 'Cc' or 'Bcc' field of the mail message, if this InputDocument is a mail message.

◆ AddRecipient() [2/2]

void TRIM.SDK.InputDocument.AddRecipient ( MailRecipientType  RecipientType,
string  mailAddress,
string  displayName,
string  mailType 
)

Adds the person described by the nominated email address and display name to the 'To', 'Cc' or 'Bcc' field of the mail message, if this InputDocument is a mail message.

◆ CleanupMailFiles()

void TRIM.SDK.InputDocument.CleanupMailFiles ( )

Removes all attachment and native mail message files, as well as any temporary file associated with this InputDocument from the hard disk.

◆ GetAttachments()

EmailAttachmentList TRIM.SDK.InputDocument.GetAttachments ( )

Gets all the attachments associated with this InputDocument

◆ GetAuthor()

EmailParticipant TRIM.SDK.InputDocument.GetAuthor ( )

Gets the author iof this email message as an EmailParticipant object

◆ GetRecipients()

EmailParticipantList TRIM.SDK.InputDocument.GetRecipients ( MailRecipientType  recipientType)

Gets the author iof this email message as an EmailParticipant object

◆ SetAsAlreadyStoredItem() [1/2]

void TRIM.SDK.InputDocument.SetAsAlreadyStoredItem ( ElectronicStore  alreadyInStore,
string  alreadyInStoreID,
long  alreadyInStoreBytes,
string  alreadyInStoreExtension 
)

Sets the Input Document to correspond to a document that has already been stored in a TRIM document store. Note that this form of the constructor is obsolete, please use the one that supplies DateModified as an extra parameter

◆ SetAsAlreadyStoredItem() [2/2]

void TRIM.SDK.InputDocument.SetAsAlreadyStoredItem ( ElectronicStore  alreadyInStore,
string  alreadyInStoreID,
long  alreadyInStoreBytes,
string  alreadyInStoreExtension,
TrimDateTime  alreadyInStoreDateModified 
)

Sets the Input Document to correspond to a document that has already been stored in a TRIM document store. Note that this does not allow multiple references to a single stored item - TRIM does not support single instancing in this way.

◆ SetAsFile()

void TRIM.SDK.InputDocument.SetAsFile ( string  fileName)

Sets the Input Document to correspond to the document at the nominated file path

◆ SetAsMailMessage() [1/2]

void TRIM.SDK.InputDocument.SetAsMailMessage ( )

Sets the Input Document to be of a TRIM mail message format (a .vmbx file). The various fields of the original email message should be copied to the corresponding fields on this Input Document object.

◆ SetAsMailMessage() [2/2]

void TRIM.SDK.InputDocument.SetAsMailMessage ( string  subject,
string  content,
TrimDateTime  sent,
TrimDateTime  received 
)

Sets the Input Document to be of a TRIM mail message format (a .vmbx file). The supplied parameters should match the original email message fields and will be used in this Input Document object.

◆ SetAsManageInPlaceItem()

void TRIM.SDK.InputDocument.SetAsManageInPlaceItem ( ElectronicStore  mipStore,
string  externalId,
long  xdocBytes,
string  xdocExtension,
TrimDateTime  xdocDateModified 
)

Sets the Input Document to correspond to an item in an document storage system that is to be managed "in place". The externalId property will be used by Content Manager to provide a view of the document with the Content Manager user interface. The format of the externalId will be suitable for the type of Manage In Place store. For Windows File System, it is the path to the document (preferable UNC path).

◆ SetAsOfflineRecord()

void TRIM.SDK.InputDocument.SetAsOfflineRecord ( OfflineRecord  offlineRecordToSetAs,
bool  UpdateAfterCheckIn 
)

Sets the InputDocument from an Offline Record

◆ SetAsOneDriveDocument()

void TRIM.SDK.InputDocument.SetAsOneDriveDocument ( string  fileName,
string  oneDriveDriveId,
string  oneDriveItemId,
string  oneDriveCTag 
)

Sets the Input Document to be based on an OneDrive document. A record created from this InputDocument will be presumed to spend most of its lifecycle in OneDrive, relying on Microsoft functionality for such things as Checking out, sharing, etc Once the record has been created, you can access the OneDrive using the ExternalEditorId property, which will be look like DriveId/items/DriveItemId, eg b!UgiVBAllpkmHZy1DJVGavKL4VWza519CgBB5T4uRNiClblKr8Q-XQpi4vzQ1_eEt/items/01NBX3FBPHWTXGMIKRZZHIC2R7QCNELYV6

◆ SetAuthor() [1/2]

void TRIM.SDK.InputDocument.SetAuthor ( EmailParticipant  newAuthor)

Sets the person described by the nominated EmailParticipant as the Author of the mail message, if this InputDocument is a mail message.

◆ SetAuthor() [2/2]

void TRIM.SDK.InputDocument.SetAuthor ( string  mailAddress,
string  displayName,
string  mailType 
)

Sets the person described by the nominated email address and display name as the Author of the mail message, if this InputDocument is a mail message.

Property Documentation

◆ AlreadyInStoreDateModified

TrimDateTime TRIM.SDK.InputDocument.AlreadyInStoreDateModified
get

Gets a datetime value indicating the date last modified of an "already stored" item. Only relevant if IsAlreadyInStore is true.

◆ AlreadyInStoreExtension

string TRIM.SDK.InputDocument.AlreadyInStoreExtension
get

Gets a String value indicating the extension of an "already stored" item. Only relevant if IsAlreadyInStore is true.

◆ AlreadyInStoreID

string TRIM.SDK.InputDocument.AlreadyInStoreID
get

Gets a String value indicating the store ID that this input document is already stored as. Only relevant if IsAlreadyInStore is true.

◆ AlreadyInStoreSize

long TRIM.SDK.InputDocument.AlreadyInStoreSize
get

Gets an Int64 value indicating the size (in bytes) of an "already stored" item. Only relevant if IsAlreadyInStore is true.

◆ AlreadyInStoreUri

TrimURI TRIM.SDK.InputDocument.AlreadyInStoreUri
get

Gets a Int64 value indicating the URI of the store that this input document is already stored in. Only relevant if IsAlreadyInStore is true.

◆ CheckinAs

string TRIM.SDK.InputDocument.CheckinAs
getset

Gets or sets a string containing the checkin path as it is to be remembered in Content Manager

◆ Content

string TRIM.SDK.InputDocument.Content
getset

Gets or sets a string containing the body (main content) of the mail message, if this InputDocument is a mail message

◆ ContentId

string TRIM.SDK.InputDocument.ContentId
getset

Gets or sets a string containing a unique hash of the content of this document ( such as a OneDrive CTag).

◆ ConversationId

string TRIM.SDK.InputDocument.ConversationId
getset

Gets or sets a string containing the conversation id of the mail message, if this InputDocument is a mail message.

◆ ExternalExtension

string TRIM.SDK.InputDocument.ExternalExtension
get

No longer used.

◆ ExternalStoreId

string TRIM.SDK.InputDocument.ExternalStoreId
get

No longer used.

◆ HasAttachments

bool TRIM.SDK.InputDocument.HasAttachments
getset

Gets or sets a boolean value indicating whether the email message has attachments. If you are passing a native email file such as .msg or .eml, this allows you to indicate the email has attachments without having to extract them and pass them into AddAttachment

◆ IsAlreadyInStore

bool TRIM.SDK.InputDocument.IsAlreadyInStore
get

Gets a boolean value indicating whether this inputDocument represents an item that has already stored in a TRIM document store. Note that this does not allow multiple references to a single item - TRIM does not support single instancing in this way.

◆ IsExternalStoreItem

bool TRIM.SDK.InputDocument.IsExternalStoreItem
get

◆ IsMailMessage

bool TRIM.SDK.InputDocument.IsMailMessage
get

Gets a Boolean value indicating whether this InputDocument is a mail message

◆ IsOfflineRecord

bool TRIM.SDK.InputDocument.IsOfflineRecord
get

Gets a boolean value indicating whether this document is an Offline Record.

◆ LocalFile

string TRIM.SDK.InputDocument.LocalFile
get

Gets a string containing the path to the document corresponding to this Input Document. If this InputDocument is a mail message, this is the path to the .vmbx file created through this InputDocument object.

◆ MessageId

string TRIM.SDK.InputDocument.MessageId
getset

Gets or sets a string containing the unique message id of the mail message, if this InputDocument is a mail message.

◆ MimeType

string TRIM.SDK.InputDocument.MimeType
getset

Gets or sets a string containing the mime type of the input document.

◆ Name

string TRIM.SDK.InputDocument.Name
get

Gets a string containing a descriptive title for this InputDocument object.

◆ NativeMailFile

string TRIM.SDK.InputDocument.NativeMailFile
getset

Gets or sets a string containing the file path to the native mail file for this mail message, if this InputDocument is a mail message.

◆ OfflineRecord

OfflineRecord TRIM.SDK.InputDocument.OfflineRecord
get

Gets the Offline Record object associated with this document.

◆ ReceivedDate

TrimDateTime TRIM.SDK.InputDocument.ReceivedDate
getset

Gets or sets the date this mail message was received, if this InputDocument is a mail message

◆ SentDate

TrimDateTime TRIM.SDK.InputDocument.SentDate
getset

Gets or sets the date the mail message was sent, if this InputDocument is a mail message

◆ Subject

string TRIM.SDK.InputDocument.Subject
getset

Gets or sets a string containing the subject of the mail message, if this InputDocument is a mail message.

◆ TimesAreUniversal

bool TRIM.SDK.InputDocument.TimesAreUniversal
getset

Gets or sets a Boolean value indicating whether the times of the 'SentDate' and 'ReceivedDate' properties of this InputDocument are based on Universal Time Coordinates / Greenwich Mean Time.

◆ UpdateOfflineRecord

bool TRIM.SDK.InputDocument.UpdateOfflineRecord
get

Gets a Boolean value indicating whether the offline record should be updated or removed as part of the check in process

◆ VerificationHash

string TRIM.SDK.InputDocument.VerificationHash
getset

Gets or sets a 64-byte MD5 hash of the document that can be used for end to end verification. When the document is submitted to the record this hash will be checked for validity, allowing an end-to-end verification mechanism to be established. For compatibility, you can calculated this hash using the Database.CalculateDocumentHash function.