Class BarcodeImageConfiguration

Definition

Namespace:
Tizen.Multimedia.Vision
Assembly:
Tizen.Multimedia.Vision.dll
API Level:
4

Represents a configuration for the image to be generated by BarcodeGenerator.

C#
Copy
public class BarcodeImageConfiguration
Inheritance
System.Object
BarcodeImageConfiguration

Constructors

View Source

BarcodeImageConfiguration(Int32, Int32, String, BarcodeImageFormat)

Initializes a new instance of the BarcodeImageConfiguration class.

Declaration
C#
Copy
public BarcodeImageConfiguration(int width, int height, string path, BarcodeImageFormat imageFormat)
Parameters
Type Name Description
Int32 width

The width of the image to be generated.

Int32 height

The height of the image to be generated.

System.String path

The path to the file to be generated.

BarcodeImageFormat imageFormat

The format of the output image.

Remarks

The mediastorage privilege (http://tizen.org/privilege/mediastorage) is needed if the image path is relevant to media storage.
The externalstorage privilege (http://tizen.org/privilege/externalstorage) is needed if the image path is relevant to external storage.

Examples
Copy
var imageConfig = new BarcodeImageConfiguration(500, 400, "/opt/usr/test-barcode-generate-new", BarcodeImageFormat.JPG);
Exceptions
Type Condition
System.ArgumentOutOfRangeException

width is less than or equal to zero.
-or-
height is less than or equal to zero.

System.ArgumentNullException

path is null.

System.ArgumentException

imageFormat is invalid.

API Level: 4
View Source

BarcodeImageConfiguration(Size, String, BarcodeImageFormat)

Initializes a new instance of the BarcodeImageConfiguration class.

Declaration
C#
Copy
public BarcodeImageConfiguration(Size size, string path, BarcodeImageFormat imageFormat)
Parameters
Type Name Description
Size size

The Size of the generated image.

System.String path

The path to the file to be generated.

BarcodeImageFormat imageFormat

The format of the output image.

Remarks

The mediastorage privilege (http://tizen.org/privilege/mediastorage) is needed if the image path is relevant to media storage.
The externalstorage privilege (http://tizen.org/privilege/externalstorage) is needed if the image path is relevant to external storage.

Examples
Copy
var imageConfig = new BarcodeImageConfiguration(new Size(500, 400), "/opt/usr/test-barcode-generate-new", BarcodeImageFormat.JPG);
Exceptions
Type Condition
System.ArgumentOutOfRangeException

The width of size is less than or equal to zero.
-or-
The height of size is less than or equal to zero.

System.ArgumentNullException

path is null.

System.ArgumentException

imageFormat is invalid.

API Level: 4

Properties

View Source

Format

Gets the format of the output image.

Declaration
C#
Copy
public BarcodeImageFormat Format { get; }
Property Value
Type Description
BarcodeImageFormat
API Level: 4
View Source

Height

Gets the height of the image.

Declaration
C#
Copy
public int Height { get; }
Property Value
Type Description
Int32
API Level: 4
View Source

Path

Gets the path to the file that has to be generated.

Declaration
C#
Copy
public string Path { get; }
Property Value
Type Description
System.String
Remarks

The mediastorage privilege (http://tizen.org/privilege/mediastorage) is needed if the image path is relevant to media storage.
The externalstorage privilege (http://tizen.org/privilege/externalstorage) is needed if the image path is relevant to external storage.

API Level: 4
View Source

Size

Gets the size of the image.

Declaration
C#
Copy
public Size Size { get; }
Property Value
Type Description
Size
API Level: 4
View Source

Width

Gets the width of the image.

Declaration
C#
Copy
public int Width { get; }
Property Value
Type Description
Int32
API Level: 4