Illustrator entry wrapper class to allow for entry creation, manipulation, storage, etc.
More...
#include <hdicoreaiEntry.h>
|
enum | Type {
UnknownType = 0
, BoolType = 10
, IntType = 20
, FloatType = 30
,
StringType = 40
, BinaryType = 50
, DictionaryType = 60
, ArrayType = 70
,
AngleType = 80
, ArtboardPointType = 90
, ArtboardRectType = 100
, ArtboardSegPointType = 110
,
ArtColorType = 120
, ArtStyleType = 130
, BezierType = 140
, ColorType = 150
,
DashStyleType = 160
, DashStyleMapType = 170
, FillStyleType = 180
, FillStyleMapType = 190
,
FontType = 200
, HitDataType = 210
, PathStyleType = 220
, PathStyleMapType = 230
,
PointType = 240
, RectType = 250
, SegPointType = 260
, SizeType = 270
,
StrokeStyleType = 280
, StrokeStyleMapType = 290
, TransformMatrixType = 300
, UIDType = 310
,
ArtType = UIDType
} |
| Describes the type of data an Entry object represents.
|
|
|
| Entry () |
| Constructs an empty Entry object.
|
|
| Entry (const Entry &e_) |
| Entry copy constructor.
|
|
| Entry (const AIEntryRef aiEntry_) |
| Constructs a new Entry object from an AIEntryRef.
|
|
virtual | ~Entry () |
| Destructs an Entry object.
|
|
virtual Entry & | operator= (const Entry &rhs_) |
| Overloaded assignment operator for Entry objects.
|
|
virtual bool | operator== (const Entry &rhs_) const |
| Tests whether a given Entry object is the same as another.
|
|
virtual bool | operator!= (const Entry &rhs_) const |
| Tests whether a given Entry object is not the same as another.
|
|
virtual bool | isEmpty () const |
| Gets whether the target Entry object is empty (constructed with the default ctor)
|
|
virtual AIEntryRef | aiEntryRef () const |
| Gets the entry ref around which the target object is wrapped.
|
|
virtual Type | entryType () const |
| Gets the type of the entry.
|
|
virtual bool | asArray (Array &array__) const |
| Gets an array value from the entry.
|
|
virtual bool | asBool (bool &value__) const |
| Gets a bool value from the entry.
|
|
virtual bool | asDict (Dictionary &dict__) const |
| Gets a dictionary value from the entry.
|
|
virtual bool | asInt (int64_t &value__) const |
| Gets an integer value from the entry.
|
|
virtual bool | asFloat (double &value__) const |
| Gets a floating-point value from the entry.
|
|
virtual bool | asString (std::string &value__) const |
| Gets a string value from the entry.
|
|
virtual bool | asUID (UID &uid__) const |
| Gets a UID value from the entry.
|
|
virtual bool | asArt (Art &art__) const |
| Gets an Art value from the entry.
|
|
|
aip::IllustratorEntry * | __accessImpl (const Entry &) |
|
Entry | __accessCtor (const aip::IllustratorEntry &) |
|
Illustrator entry wrapper class to allow for entry creation, manipulation, storage, etc.
◆ Entry() [1/3]
hdi::core::ai::Entry::Entry |
( |
| ) |
|
Constructs an empty Entry object.
- Author
- GW
- Date
- 08/2013
- Note
- To test if an Entry object is empty, call isEmpty() on it
-
Empty Entry objects do not relate to any actual data; they are designed to be "receivers" of some other Entry object via the overloaded assignment operator. Empty Entry objects are useless until such time (though it is safe to call any of their methods)
◆ Entry() [2/3]
hdi::core::ai::Entry::Entry |
( |
const Entry & |
e_ | ) |
|
Entry copy constructor.
- Author
- GW
- Date
- 08/2013
- Parameters
-
◆ Entry() [3/3]
hdi::core::ai::Entry::Entry |
( |
const AIEntryRef |
aiEntry_ | ) |
|
Constructs a new Entry object from an AIEntryRef.
- Author
- GW
- Date
- 08/2015
- Parameters
-
◆ ~Entry()
virtual hdi::core::ai::Entry::~Entry |
( |
| ) |
|
|
virtual |
Destructs an Entry object.
- Author
- GW
- Date
- 08/2013
◆ aiEntryRef()
virtual AIEntryRef hdi::core::ai::Entry::aiEntryRef |
( |
| ) |
const |
|
virtual |
Gets the entry ref around which the target object is wrapped.
- Author
- GW
- Date
- 11/2013
- Returns
- AIEntryRef for the target object
- Note
- The caller should not release the returned AIEntryRef (its reference count is not increased before being returned).
-
Generally, you shouldn't need to call this method. Only use it if you know what you're doing. If a specific piece of functionality provided by Illustrator is not handled by this class (or related classes), then it should probably be added to the hdi_core library.
◆ asArray()
virtual bool hdi::core::ai::Entry::asArray |
( |
Array & |
array__ | ) |
const |
|
virtual |
Gets an array value from the entry.
- Author
- GW
- Date
- 08/2013
- Parameters
-
array__ | Return-by-reference for the array value the entry is wrapped around |
- Returns
- true if the entry is of type ArrayType and array__ can be acquired, false otherwise
◆ asArt()
virtual bool hdi::core::ai::Entry::asArt |
( |
Art & |
art__ | ) |
const |
|
virtual |
Gets an Art value from the entry.
- Author
- GW
- Date
- 08/2013
- Parameters
-
art__ | Return-by-reference for the Art value the entry is wrapped around |
- Returns
- true if the entry is of type ArtType and art__ can be acquired, false otherwise
◆ asBool()
virtual bool hdi::core::ai::Entry::asBool |
( |
bool & |
value__ | ) |
const |
|
virtual |
Gets a bool value from the entry.
- Author
- GW
- Date
- 08/2013
- Parameters
-
value__ | Return-by-reference for the bool value the entry is wrapped around |
- Returns
- true if the entry is of type BoolType and value__ can be acquired, false otherwise
◆ asDict()
virtual bool hdi::core::ai::Entry::asDict |
( |
Dictionary & |
dict__ | ) |
const |
|
virtual |
Gets a dictionary value from the entry.
- Author
- GW
- Date
- 08/2013
- Parameters
-
dict__ | Return-by-reference for the dictionary value the entry is wrapped around |
- Returns
- true if the entry is of type DictionaryType and dict__ can be acquired, false otherwise
◆ asFloat()
virtual bool hdi::core::ai::Entry::asFloat |
( |
double & |
value__ | ) |
const |
|
virtual |
Gets a floating-point value from the entry.
- Author
- GW
- Date
- 08/2013
- Parameters
-
value__ | Return-by-reference for the floating point value the entry is wrapped around |
- Returns
- true if the entry is of type FloatType and value__ can be acquired, false otherwise
◆ asInt()
virtual bool hdi::core::ai::Entry::asInt |
( |
int64_t & |
value__ | ) |
const |
|
virtual |
Gets an integer value from the entry.
- Author
- GW
- Date
- 08/2013
- Parameters
-
value__ | Return-by-reference for the integer value the entry is wrapped around |
- Returns
- true if the entry is of type IntType and value__ can be acquired, false otherwise
◆ asString()
virtual bool hdi::core::ai::Entry::asString |
( |
std::string & |
value__ | ) |
const |
|
virtual |
Gets a string value from the entry.
- Author
- GW
- Date
- 08/2013
- Parameters
-
value__ | Return-by-reference for the UTF-8 string value the entry is wrapped around |
- Returns
- true if the entry is of type StringType and value__ can be acquired, false otherwise
◆ asUID()
virtual bool hdi::core::ai::Entry::asUID |
( |
UID & |
uid__ | ) |
const |
|
virtual |
Gets a UID value from the entry.
- Author
- GW
- Date
- 08/2013
- Parameters
-
uid__ | Return-by-reference for the UID value the entry is wrapped around |
- Returns
- true if the entry is of type UIDType and uid__ can be acquired, false otherwise
◆ entryType()
virtual Type hdi::core::ai::Entry::entryType |
( |
| ) |
const |
|
virtual |
Gets the type of the entry.
- Author
- GW
- Date
- 08/2013
- Returns
- An enum value describing the type of the entry
◆ FromArray()
static Entry hdi::core::ai::Entry::FromArray |
( |
const Array & |
value_ | ) |
|
|
static |
Statically constructs an Entry object from a given array.
- Author
- GW
- Date
- 08/2013
- Parameters
-
value_ | Array value for the new entry |
- Returns
- An Entry object that contains the provided Array object
◆ FromArt()
static Entry hdi::core::ai::Entry::FromArt |
( |
const Art & |
value_ | ) |
|
|
static |
Statically constructs an Entry object from a given Art object.
- Author
- GW
- Date
- 08/2013
- Parameters
-
value_ | Art value for the new entry |
- Returns
- An Entry object that contains the provided Art object
◆ FromBool()
static Entry hdi::core::ai::Entry::FromBool |
( |
const bool |
value_ | ) |
|
|
static |
Statically constructs an Entry object from a given bool.
- Author
- GW
- Date
- 08/2013
- Parameters
-
value_ | bool value for the new entry |
- Returns
- An Entry object that contains the provided bool value
◆ FromDict()
Statically constructs an Entry object from a given dictionary.
- Author
- GW
- Date
- 08/2013
- Parameters
-
- Returns
- An Entry object that contains the provided Dictionary object
◆ FromFloat()
static Entry hdi::core::ai::Entry::FromFloat |
( |
const double |
value_ | ) |
|
|
static |
Statically constructs an Entry object from a given floating point.
- Author
- GW
- Date
- 08/2013
- Parameters
-
value_ | Floating point value for the new entry |
- Returns
- An Entry object that contains the provided double value
- Note
- This method compensates for values that are NaN by converting them to 0, and compensates for values that are -infinity or infinity by converting them to -FLT_MAX or FLT_MAX, respectively.
◆ FromInt()
static Entry hdi::core::ai::Entry::FromInt |
( |
const int64_t |
value_ | ) |
|
|
static |
Statically constructs an Entry object from a given integer.
- Author
- GW
- Date
- 08/2013
- Parameters
-
value_ | Integer value for the new entry |
- Returns
- An Entry object that contains the provided integer value
◆ FromString()
static Entry hdi::core::ai::Entry::FromString |
( |
const std::string & |
value_ | ) |
|
|
static |
Statically constructs an Entry object from a given string.
- Author
- GW
- Date
- 08/2013
- Parameters
-
value_ | UTF-8 string value for the new entry |
- Returns
- An Entry object that contains the provided string value
◆ FromUID()
static Entry hdi::core::ai::Entry::FromUID |
( |
const UID & |
value_ | ) |
|
|
static |
Statically constructs an Entry object from a given UID object.
- Author
- GW
- Date
- 08/2013
- Parameters
-
value_ | UID value for the new entry |
- Returns
- An Entry object that contains the provided UID object
◆ isEmpty()
virtual bool hdi::core::ai::Entry::isEmpty |
( |
| ) |
const |
|
virtual |
Gets whether the target Entry object is empty (constructed with the default ctor)
- Author
- GW
- Date
- 08/2013
- Returns
- true if the target Entry object is empty, false otherwise
◆ operator!=()
virtual bool hdi::core::ai::Entry::operator!= |
( |
const Entry & |
rhs_ | ) |
const |
|
virtual |
Tests whether a given Entry object is not the same as another.
- Author
- GW
- Date
- 08/2013
- Parameters
-
rhs_ | Entry to compare against (righthand side of inequality operator) |
- Returns
- true for the target and rhs_ being different entries, false otherwise
◆ operator=()
virtual Entry & hdi::core::ai::Entry::operator= |
( |
const Entry & |
rhs_ | ) |
|
|
virtual |
Overloaded assignment operator for Entry objects.
- Author
- GW
- Date
- 08/2013
- Parameters
-
rhs_ | Righthand side of the assignment operator; existing Entry object that the target should reference instead |
- Returns
- The lefthand side of the assignment operator, but now referencing the same entry data as the righthand side
◆ operator==()
virtual bool hdi::core::ai::Entry::operator== |
( |
const Entry & |
rhs_ | ) |
const |
|
virtual |
Tests whether a given Entry object is the same as another.
- Author
- GW
- Date
- 08/2013
- Parameters
-
rhs_ | Entry to compare against (righthand side of equality operator) |
- Returns
- true for the target and rhs_ being the same entry, false otherwise