Class IsoCoordinateTable
Coordinate table for NC controller. The dictionary key is 1000times coordinate index (ex. G54 is 54000); the dictionary value is machine coordinate.
public class IsoCoordinateTable : Dictionary<int, Vec3d>, IDictionary<int, Vec3d>, ICollection<KeyValuePair<int, Vec3d>>, IReadOnlyDictionary<int, Vec3d>, IReadOnlyCollection<KeyValuePair<int, Vec3d>>, IEnumerable<KeyValuePair<int, Vec3d>>, IDictionary, ICollection, IEnumerable, IDeserializationCallback, ISerializable, IMakeXmlSource
- Inheritance
-
IsoCoordinateTable
- Implements
- Inherited Members
- Extension Methods
Constructors
IsoCoordinateTable()
Ctor.
public IsoCoordinateTable()
IsoCoordinateTable(XElement)
Initializes a new instance of the IsoCoordinateTable class from XML.
public IsoCoordinateTable(XElement src)
Parameters
src
XElementThe XML element containing coordinate data.
Fields
XName
Gets the XML element name for the IsoCoordinateTable.
public static string XName
Field Value
Methods
GetCoordinateString(int)
Gets the coordinate string representation for a given coordinate key.
public string GetCoordinateString(int coordinateKey)
Parameters
coordinateKey
intThe coordinate key to get the string for.
Returns
- string
A string representation of the coordinate, e.g. “G54” for key 54000.
MakeXmlSource(string, string)
Creates an XML representation of the object. This method may also generate additional resources such as related files.
public XElement MakeXmlSource(string baseDirectory, string relFile)
Parameters
baseDirectory
stringThe base directory for resolving relative paths
relFile
stringThe relative file path for the XML source
Returns
- XElement
An XML element representing the object's state
Remarks
For the demand of easy moving source folder (especially project folder) without configuration file path corruption, the relative file path is applied.
The baseDirectory
is typically the folder at the nearest configuration file folder.
Since the folder can be moving with the configuration file.