Attachment constructor
init
Initializes new instance of Attachment class.
init
Initializes new instance of Attachment class.
def __init__(self, file_name, file_path):
...
| Parameter |
Type |
Description |
| file_name |
System.String |
Attachment file name. |
| file_path |
System.String |
Attachment relative path e.g. folder/file.docx or filename when the file is located in the root of an archive, in e-mail message or data file. |
Exceptions
| Exception |
Description |
| ArgumentException |
Thrown when file_name is null or empty. |
| ArgumentException |
Thrown when file_path is null or empty. |
init
Initializes new instance of Attachment class.
def __init__(self, id, file_name, file_path, size):
...
| Parameter |
Type |
Description |
| id |
System.String |
Unique (in context of single file) identifier of the attachment. |
| file_name |
System.String |
Attachment file name. |
| file_path |
System.String |
Attachment relative path e.g. folder/file.docx or filename when the file is located in the root of an archive, in e-mail message or data file. |
| size |
int |
Attachment file size in bytes. |
Exceptions
| Exception |
Description |
| ArgumentException |
Thrown when id is null or empty. |
| ArgumentException |
Thrown when file_name is null or empty. |
| ArgumentException |
Thrown when file_path is null or empty. |
init
Initializes new instance of Attachment class.
def __init__(self, id, file_name, file_path, file_type, size):
...
| Parameter |
Type |
Description |
| id |
System.String |
Unique (in context of single file) identifier of the attachment. |
| file_name |
System.String |
Attachment file name. |
| file_path |
System.String |
Attachment relative path e.g. folder/file.docx or filename when the file is located in the root of an archive, in e-mail message or data file. |
| file_type |
groupdocs.viewer.FileType |
Attachment file type. |
| size |
int |
Attachment file size in bytes. |
Exceptions
| Exception |
Description |
| ArgumentException |
Thrown when id is null or empty. |
| ArgumentException |
Thrown when file_name is null or empty. |
| ArgumentException |
Thrown when file_path is null or empty. |
| ArgumentNullException |
Thrown when file_type is null. |
See Also