Table of Contents

Class AdsVariable

Namespace
Loehnert.Lisrt.IO.Beckhoff.Ads
Assembly
Loehnert.Lisrt.IO.Beckhoff.dll

Represents an ads variable.

public class AdsVariable : PropertyChangedBase, INotifyPropertyChangedEx, INotifyPropertyChanged
Inheritance
PropertyChangedBase
AdsVariable
Implements
INotifyPropertyChangedEx
Inherited Members
PropertyChangedBase.Refresh()
PropertyChangedBase.IsNotifying
PropertyChangedBase.PropertyChanged

Constructors

AdsVariable(string, ushort)

Initializes a new instance of the AdsVariable class.

public AdsVariable(string searchString, ushort size)

Parameters

searchString string

the search string to find the variable.

size ushort

The byte size.

Exceptions

ArgumentException

Thrown when searchString is null, empty or whitespace.

Properties

Name

Gets or sets the full symbol name. Default value is SearchString.

public virtual string Name { get; set; }

Property Value

string

RawData

Gets the raw data.

public byte[] RawData { get; }

Property Value

byte[]

SearchString

Gets the search string to find the variable.

public string SearchString { get; }

Property Value

string

Size

Gets the byte size.

public ushort Size { get; }

Property Value

ushort

Methods

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

A string that represents the current object.

UpdateRawData(byte[])

Updates the raw data.

public void UpdateRawData(byte[] rawData)

Parameters

rawData byte[]

New raw data.

Exceptions

ArgumentNullException

Thrown when rawData is null.

ArgumentException

Thrown when rawData.Length is not equal to Size.

Events

RawValuesChanged

Occurs when the RawData value changes.

public event EventHandler<RawValueChangedEventArgs> RawValuesChanged

Event Type

EventHandler<RawValueChangedEventArgs>