Files
wwtools/aot/reference/CMxIndirectBase.md
Joseph Doherty 32f26272ae Initial commit: Wonderware / System Platform tools and reference
Five tools under one repo, all docs organized per DOCS-GUIDE.md:

- aalogcli: .NET 4.8 / x86 CliFx CLI for reading System Platform binary
  logs (*.aaLGX) for LLM debugging, built on aaOpenSource/aaLog. Commands:
  last, tail, range, unread, fields. Stable JSON envelope under --llm-json.
  Build template under lib/build/ for rebuilding aaLogReader.dll.

- aot: ArchestrA Object Toolkit 2014 v4.0 reference material. Dev guide
  (Markdown converted from CHM), API reference for the ArchestrA.Toolkit
  namespace, and the Monitor / Watchdog VS sample solutions.

- graccesscli: .NET 4.8 / x86 CliFx CLI that automates Galaxy
  configuration via the ArchestrA GRAccess COM interop. Includes session
  daemon, IPC protocol, and llm-json envelope contract.

- grdb: SQL/DDL exploration of the Galaxy Repository database. DDL
  captures, reusable queries, hierarchy / contained-name <-> tag-name
  translation notes.

- histdb: LLM-oriented reference for AVEVA Historian retrieval. INSQL
  linked-server, extension tables, every wwXxx time-domain extension,
  every retrieval mode, alarm/event SQL recipes, REST API. Distilled
  from the 243-page Historian Retrieval Guide.

Root contains:
- CLAUDE.md: thin index pointing into each tool's README.
- DOCS-GUIDE.md: doctrine for organizing docs for LLM consumption.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-03 18:22:20 -04:00

274 lines
4.4 KiB
Markdown

# CMxIndirectBase Class
Namespace: `ArchestrA.Toolkit`
CMxIndirectBase is an inherited class that provides methods and properties common to the two types of Indirects: CMxIndirect and CMxIndirectWriteOnly.
**Syntax**
```csharp
public class CMxIndirectBase
```
## CMxIndirectBase Properties
### Context Property
The context that was used to create the indirect.
**Syntax**
```csharp
public string Context { get; }
```
**Returns**
string
### FullReferenceString Property
The reference string that was used to create the CMXIndirectBase instance.
**Syntax**
```csharp
public string FullReferenceString { get; }
```
**Returns**
string
### HasTimedOut Property
Indirects contains a timer that tracks how long it successfully connected to its remote attribute. If this time is longer than the TimeOut value, then this property returns true.
**Syntax**
```csharp
public bool HasTimedOut { get; }
```
**Returns**
bool
### RefHandle Property
The RefHandle is the ArchestrA id for the reference bound to this Indirect.
**Syntax**
```csharp
public int RefHandle { get; }
```
**Returns**
int
### StatusId Property
The status of a write is written to a dynamic attribute array. This is attribute id of the dynamic array.
**Syntax**
```csharp
public short StatusId { get; }
```
**Returns**
short
### StatusIndex Property
The status of a write is written to a dynamic attribute array. This is the index of the element of that array that this indirect will write its status to.
**Syntax**
```csharp
public int StatusIndex { get; }
```
**Returns**
int
### StatusOfLastWrite Property
This returns the status value of the last write attempt from the dynamic attribute array.
A user can monitor this value to seen when a write has completed, successfully or otherwise.
**Syntax**
```csharp
public MxStatus StatusOfLastWrite { get; }
```
**Returns**
MxStatus
### TimeOut Property
Allows the user the set the TimeOut used by HasTimedOut.
**Syntax**
```csharp
public TimeSpan TimeOut { get; set; }
```
**Returns**
TimeSpan
## CMxIndirectBase Constructor
### CMxIndirectBase Constructor string, string, ArchestrA.Core.IMxSupervisoryConnection3, RuntimeBase, int, short, int
This is an internal constructor intended for use only by derived classes.
**Syntax**
```csharp
CMxIndirectBase(string _fullRefString, string _context, ArchestrA.Core.IMxSupervisoryConnection3 _superConn, RuntimeBase _rb, int _refHandle, short _statusId, int _statusIndex)
```
**Parameters**
**`_fullRefString`**
[in] Full reference string of the attribute to bind to.
**`_context`**
[in] Context of the reference.
**`_superConn`**
[in] A supervisory connection to the runtime.
**`_rb`**
[in] A handle to the RuntimeBase class instance that created this indirect.
**`_refHandle`**
[in] The ArchestrA reference handle of the registered reference.
**`_statusId`**
[in] The attribute id of the dynamic array that holds the write status's.
**`_statusIndex`**
[in] The index of the element in the dynamic status array that this reference uses.
## CMxIndirectBase Methods
### Activate Method
Activates a suspended indirect.
**Syntax**
```csharp
public bool Activate();
```
**Returns**
bool
### Activate Method(ArchestrA.MessageExchange.IMxCallback2)
Activates a suspended indirect and allows the user to supply a callback variable.
**Syntax**
```csharp
public bool Activate(ArchestrA.MessageExchange.IMxCallback2 callback)
```
**Parameters**
**`callback`**
[in] The callback supplied by the user to be called when the Activate has finished.
**Returns**
bool
### Set Method(CMxValue, DateTime)
Writes the value and timestamp to the indirect in a single operation.
**Syntax**
```csharp
public bool Set(CMxValue value, DateTime timeStamp)
```
**Parameters**
**`value`**
[in] The value to be written.
**`timeStamp`**
[in] The timestamp for the value.
**Returns**
bool
### Suspend Method
Suspends an active indirect.
**Syntax**
```csharp
public bool Suspend()
```
**Returns**
bool
### Suspend Method (ArchestrA.MessageExchange.IMxCallback2)
Suspends an active indirect and allows the user to supply a callback variable.
**Syntax**
```csharp
public bool Suspend(ArchestrA.MessageExchange.IMxCallback2 callback)
```
**Parameters**
**`callback`**
[in] The callback supplied by the user to be called when the Suspend has finished.
**Returns**
bool
### Unbind Method
Unbinds the indirect, releasing the ArchestrA reference and dynamic status array index.
**Syntax**
```csharp
public void Unbind()
```