C# Class rosette_api.RosetteFile

RosetteFile Class

RosetteFile: Custom Datatype containing information about files for upload, and methods to read the files

Datei anzeigen Open project: rosette-api/csharp Class Usage Examples

Public Methods

Method Description
AsMultipart ( ) : System.Net.Http.MultipartFormDataContent

AsMultipart creates a multipart form data object containing the file contents, aka "content" and, optionally, the options, identified as "request".

Dispose ( ) : void

Dispose method for RosetteFile - cleans things up

RosetteFile ( string fileName, string contentType = "text/plain", string options = null ) : System

RosetteFile

RosetteFile: Custom Datatype containing information about files for upload, and methods to read the files

getFileData ( ) : byte[]

getFileData

getFileData: Get the FileData in byte form

getFileDataString ( ) : string

getFileDataString

getFileDataString: Get the FileData in string form

Protected Methods

Method Description
Dispose ( bool disposing ) : void

Virtual Dispose that is actually used by the class

Method Details

AsMultipart() public method

AsMultipart creates a multipart form data object containing the file contents, aka "content" and, optionally, the options, identified as "request".
public AsMultipart ( ) : System.Net.Http.MultipartFormDataContent
return System.Net.Http.MultipartFormDataContent

Dispose() public method

Dispose method for RosetteFile - cleans things up
public Dispose ( ) : void
return void

Dispose() protected method

Virtual Dispose that is actually used by the class
protected Dispose ( bool disposing ) : void
disposing bool
return void

RosetteFile() public method

RosetteFile

RosetteFile: Custom Datatype containing information about files for upload, and methods to read the files

public RosetteFile ( string fileName, string contentType = "text/plain", string options = null ) : System
fileName string string: Path to the data file
contentType string (string, optional): Description of the content type of the data file. "text/plain" is used if unsure.
options string (string, optional): Json string to add extra information
return System

getFileData() public method

getFileData

getFileData: Get the FileData in byte form

public getFileData ( ) : byte[]
return byte[]

getFileDataString() public method

getFileDataString

getFileDataString: Get the FileData in string form

public getFileDataString ( ) : string
return string