Show / Hide Table of Contents

Class ProductInfo

Holds information about a product. Part Number, Name and child/parent relations.

Inheritance
System.Object
ProductInfo
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Virinco.WATS.Interface.MES.Product
Assembly: Virinco.WATS.Interface.MES.dll
Syntax
public class ProductInfo

Constructors

ProductInfo(ProductInfoJson, List<ProductInfoJson>)

Declaration
public ProductInfo(ProductInfoJson pir, List<ProductInfoJson> pirl)
Parameters
Type Name Description
ProductInfoJson pir
System.Collections.Generic.List<ProductInfoJson> pirl

Properties

Name

The product's Name

Declaration
public string Name { get; }
Property Value
Type Description
System.String

PartNumber

The product's Part Number

Declaration
public string PartNumber { get; }
Property Value
Type Description
System.String

Product_Data

Data attached to product. May be queried by GetTagValue(String, Int32)

Declaration
public string Product_Data { get; }
Property Value
Type Description
System.String

ProductCategory

The product's category

Declaration
public string ProductCategory { get; }
Property Value
Type Description
System.String

ProductDescription

The product's description

Declaration
public string ProductDescription { get; }
Property Value
Type Description
System.String

Quantity

How many units like this Product Info object does the parent contain.

Declaration
public int? Quantity { get; }
Property Value
Type Description
System.Nullable<System.Int32>

Revision

The product's Revision

Declaration
public string Revision { get; }
Property Value
Type Description
System.String

Revision_Data

Data attached to product revision. May be queried by GetTagValue(String, Int32)

Declaration
public string Revision_Data { get; }
Property Value
Type Description
System.String

RevisionDescription

The revision's description

Declaration
public string RevisionDescription { get; }
Property Value
Type Description
System.String

RevisionName

The product's Revision name

Declaration
public string RevisionName { get; }
Property Value
Type Description
System.String

Methods

GetChild(Int32)

Get Child ProductInfo object at index

Declaration
public ProductInfo GetChild(int index)
Parameters
Type Name Description
System.Int32 index
Returns
Type Description
ProductInfo

GetChildCount()

Get the number of child ProductInfo objects

Declaration
public int GetChildCount()
Returns
Type Description
System.Int32

Number of child products or -1 of unknown

GetChildren()

Get Child ProductInfo objects

Declaration
public ProductInfo[] GetChildren()
Returns
Type Description
ProductInfo[]

GetInfo(String)

Query Product XML data given a XPath

Declaration
public string GetInfo(string XPath)
Parameters
Type Name Description
System.String XPath

The XPath to query

Returns
Type Description
System.String

XPath query result as string

GetParent()

Get parent ProductInfo object

Declaration
public ProductInfo GetParent()
Returns
Type Description
ProductInfo

GetTagValue(String, Int32)

Query data attached to product or revision.

Declaration
public string GetTagValue(string Tag, int Type)
Parameters
Type Name Description
System.String Tag

Name of Tag

System.Int32 Type

Type of XML data (1=ProductData,2=RevisionData)

Returns
Type Description
System.String

Tag value

HasParent()

Indicates if the product is a top level product

Declaration
public bool HasParent()
Returns
Type Description
System.Boolean

Boolean value indicating if the product has any parent products.

In This Article
Back to top View how-to articles, videos and more at support.virinco.com Send comments on this topic to support@virinco.com