Gocator API
 All Classes Files Functions Variables Typedefs Macros Groups Pages
GoTool.h
Go to the documentation of this file.
1 /**
2  * @file GoTool.h
3  * @brief Declares the base GoTool class.
4  *
5  * @internal
6  * Copyright (C) 2014 by LMI Technologies Inc.
7  * Licensed under the MIT License.
8  * Redistributed files must retain the above copyright notice.
9  */
10 #ifndef GO_TOOL_H
11 #define GO_TOOL_H
12 
13 #include <GoSdk/GoSdkDef.h>
15 #include <kApi/Data/kXml.h>
17 
18 /**
19  * @class GoTool
20  * @extends kObject
21  * @ingroup GoSdk-Tools
22  * @brief Represents the base tool class.
23  */
24 typedef kObject GoTool;
25 
26 /**
27  * Returns the measurement count.
28  *
29  * @public @memberof GoTool
30  * @param tool GoTool object.
31  * @return The measurement count.
32  */
33 GoFx(kSize) GoTool_MeasurementCount(GoTool tool);
34 
35 /**
36  * Retrieves the measurement at the given index.
37  *
38  * @public @memberof GoTool
39  * @param tool GoTool object.
40  * @param index The index of the measurement.
41  * @return The measurement at the given index or kNULL if an invalid index is provided.
42  */
43 GoFx(GoMeasurement) GoTool_MeasurementAt(GoTool tool, kSize index);
44 
45 /**
46  * Sets the name of the tool.
47  *
48  * @public @memberof GoTool
49  * @param tool GoTool object.
50  * @param name The name to be set for the tool.
51  * @return Operation status.
52  */
53 GoFx(kStatus) GoTool_SetName(GoTool tool, const kChar* name);
54 
55 /**
56  * Retrieves the name of the tool.
57  *
58  * @public @memberof GoTool
59  * @param tool GoTool object.
60  * @param name Receives the name of the tool.
61  * @param capacity The maximum capacity of the name array.
62  * @return Operation status.
63  */
64 GoFx(kStatus) GoTool_Name(GoTool tool, kChar* name, kSize capacity);
65 
66 /**
67  * Retrieves the tool type enumeration value of the tool.
68  *
69  * @public @memberof GoTool
70  * @param tool GoTool object.
71  * @return The tool type enumeration value.
72  */
73 GoFx(GoToolType) GoTool_Type(GoTool tool);
74 
75 /**
76  * Retrieves the first found instance of a measurement for a given enumeration type.
77  *
78  * @public @memberof GoTool
79  * @param tool GoTool object.
80  * @param type A GoMeasurementType representing the measurement type to find in the given tool.
81  * @return A measurement object if one is found, otherwise kNULL.
82  */
84 
85 kEndHeader()
86 #include <GoSdk/Tools/GoTool.x.h>
87 
88 #endif
GoMeasurement GoTool_FindMeasurementByType(GoTool tool, GoMeasurementType type)
Retrieves the first found instance of a measurement for a given enumeration type. ...
Lists all tool types.
Represents the base class for a tool measurement or script output.
Definition: GoMeasurement.h:15
GoToolType GoTool_Type(GoTool tool)
Retrieves the tool type enumeration value of the tool.
Lists all measurement types.
kStatus GoTool_Name(GoTool tool, kChar *name, kSize capacity)
Retrieves the name of the tool.
kStatus GoTool_SetName(GoTool tool, const kChar *name)
Sets the name of the tool.
kSize GoTool_MeasurementCount(GoTool tool)
Returns the measurement count.
Essential SDK declarations.
Declares the GoMeasurement classes.
Represents the base tool class.
Definition: GoTool.h:16
kBeginHeader() kStatus GoSdk_Construct(kAssembly *assembly)
Constructs the Gocator SDK library.
GoMeasurement GoTool_MeasurementAt(GoTool tool, kSize index)
Retrieves the measurement at the given index.