Adobe.com
Contents Files

SoSharedLibDefs.h File Reference


Detailed Description

The ExtendScript header file used to implement external objects.

Definition in file SoSharedLibDefs.h.

Go to the source code of this file.

Classes

struct  TaggedData_s
 All data is passed in and out in a tagged data structure. More...

Defines

#define kESErrOK   0
 This is the C header file which you need to write DLLs that ExtendScript can load at runtime.
#define kESErrNoLvalue   3
 Cannot assign value (ReferenceError).
#define kESErrOpenString   4
 Unterminated string constant (SyntaxError).
#define kESErrBadDigit   6
 Bad digit in number (SyntaxError).
#define kESErrSyntax   8
 Syntax error (SyntaxError).
#define kESErrBadArgumentList   20
 Bad argument list (TypeError).
#define kESErrNoMemory   -28
 Out of memory.
#define kESErrException   -29
 Uncaught exception.
#define kESErrBadURI   31
 Bad URI (URIError).
#define kESErrBadAction   32
 Cannot perform requested action (Error).
#define kESErrInternal   -33
 Internal error.
#define kESErrNotImplemented   -36
 Not yet implemented.
#define kESErrRange   41
 1 is out of range (RangeError)
#define kESErrEval   43
 Evaluation error (EvalError).
#define kESErrConversion   44
 Cannot convert (TypeError).
#define kESErrInvalidObject   45
 Object is invalid (ReferenceError).
#define kESErrTypeMismatch   47
 Type mismatch (TypeError).
#define kESErrNoFile   48
 File or folder does not exist.
#define kESErrFileExists   49
 File or folder already exists.
#define kESErrNotOpen   50
 I/O device is not open.
#define kESErrEOF   51
 Read past EOF.
#define kESErrIO   52
 I/O error.
#define kESErrNoPermission   53
 Permission denied.
#define kESErrCannotResolve   57
 Cannot resolve reference.
#define kESErrIOTimeout   58
 I/O Timeout.
#define kESErrNoResponse   59
 No response.
#define kTypeUndefined   0
 The possible VariantData data types.
#define kTypeBool   2
 A boolean value is either interpreted as false (if the value is zero) or true (if the value is nonzero).
#define kTypeDouble   3
 A double floating point value (64 bits).
#define kTypeString   4
 A string value.
#define kTypeLiveObject   6
 An object value is a pointer to a LiveObject.
#define kTypeLiveObjectRelease   7
 An object value is a pointer to a LiveObject.
#define kTypeInteger   123
 An integer value is a signed 32-bit quantity.
#define kTypeUInteger   124
 An unsigned integer value is an unsigned 32-bit quantity.
#define kTypeScript   125
 A script is an executable string.

Typedefs

typedef struct TaggedData_s TaggedData
typedef long(* ESFunction )(TaggedData *argv, long argc, TaggedData *retval)
 All functions need to be coded in the same way, following the function definition below.
typedef signed long ESerror_t


Define Documentation

#define kESErrBadAction   32

Cannot perform requested action (Error).

Definition at line 50 of file SoSharedLibDefs.h.

#define kESErrBadArgumentList   20

#define kESErrBadDigit   6

Bad digit in number (SyntaxError).

Definition at line 38 of file SoSharedLibDefs.h.

#define kESErrBadURI   31

Bad URI (URIError).

Definition at line 48 of file SoSharedLibDefs.h.

#define kESErrCannotResolve   57

Cannot resolve reference.

Definition at line 78 of file SoSharedLibDefs.h.

#define kESErrConversion   44

Cannot convert (TypeError).

Definition at line 60 of file SoSharedLibDefs.h.

#define kESErrEOF   51

Read past EOF.

Definition at line 72 of file SoSharedLibDefs.h.

#define kESErrEval   43

Evaluation error (EvalError).

Definition at line 58 of file SoSharedLibDefs.h.

#define kESErrException   -29

Uncaught exception.

Definition at line 46 of file SoSharedLibDefs.h.

#define kESErrFileExists   49

File or folder already exists.

Definition at line 68 of file SoSharedLibDefs.h.

#define kESErrInternal   -33

Internal error.

Definition at line 52 of file SoSharedLibDefs.h.

#define kESErrInvalidObject   45

Object is invalid (ReferenceError).

Definition at line 62 of file SoSharedLibDefs.h.

#define kESErrIO   52

I/O error.

Definition at line 74 of file SoSharedLibDefs.h.

#define kESErrIOTimeout   58

I/O Timeout.

Definition at line 80 of file SoSharedLibDefs.h.

#define kESErrNoFile   48

File or folder does not exist.

Definition at line 66 of file SoSharedLibDefs.h.

#define kESErrNoLvalue   3

Cannot assign value (ReferenceError).

Definition at line 34 of file SoSharedLibDefs.h.

#define kESErrNoMemory   -28

Out of memory.

Definition at line 44 of file SoSharedLibDefs.h.

Referenced by built(), paramAny(), and paramString().

#define kESErrNoPermission   53

Permission denied.

Definition at line 76 of file SoSharedLibDefs.h.

#define kESErrNoResponse   59

No response.

Definition at line 82 of file SoSharedLibDefs.h.

#define kESErrNotImplemented   -36

Not yet implemented.

Definition at line 54 of file SoSharedLibDefs.h.

#define kESErrNotOpen   50

I/O device is not open.

Definition at line 70 of file SoSharedLibDefs.h.

#define kESErrOK   0

This is the C header file which you need to write DLLs that ExtendScript can load at runtime.

The list of runtime errors. Errors with negative values are considered fatal and cannot be caught by Javascript. This is a subset of all possible runtime errors. Please do not use other error codes. No error

Definition at line 32 of file SoSharedLibDefs.h.

Referenced by acceptBoolean(), appendString(), built(), createArray(), getAverage(), makeArray(), myScript(), objectCall(), objectFinalize(), objectGet(), objectInitialize(), objectToString(), objectValueOf(), paramAny(), paramBool(), paramFloat64(), paramInt32(), paramString(), paramUInt32(), and setVersion().

#define kESErrOpenString   4

Unterminated string constant (SyntaxError).

Definition at line 36 of file SoSharedLibDefs.h.

#define kESErrRange   41

1 is out of range (RangeError)

Definition at line 56 of file SoSharedLibDefs.h.

#define kESErrSyntax   8

Syntax error (SyntaxError).

Definition at line 40 of file SoSharedLibDefs.h.

#define kESErrTypeMismatch   47

Type mismatch (TypeError).

Definition at line 64 of file SoSharedLibDefs.h.

Referenced by objectCall(), paramAny(), paramBool(), paramFloat64(), paramInt32(), paramString(), and paramUInt32().

#define kTypeBool   2

A boolean value is either interpreted as false (if the value is zero) or true (if the value is nonzero).

The field is intval, the value is 0 or 1.

Definition at line 118 of file SoSharedLibDefs.h.

Referenced by acceptBoolean(), paramAny(), paramBool(), and stringize().

#define kTypeDouble   3

A double floating point value (64 bits).

The field is fltval.

Definition at line 121 of file SoSharedLibDefs.h.

Referenced by getAverage(), objectCall(), objectGet(), paramAny(), paramFloat64(), and stringize().

#define kTypeInteger   123

An integer value is a signed 32-bit quantity.

The field is intval.

Definition at line 139 of file SoSharedLibDefs.h.

Referenced by objectCall(), objectGet(), paramAny(), paramInt32(), and stringize().

#define kTypeLiveObject   6

An object value is a pointer to a LiveObject.

The field is hObject. A LiveObject pointer returned as a function result is not released

Definition at line 132 of file SoSharedLibDefs.h.

#define kTypeLiveObjectRelease   7

An object value is a pointer to a LiveObject.

The field is hObject. A LiveObject pointer returned as a function result is released

Definition at line 136 of file SoSharedLibDefs.h.

#define kTypeScript   125

A script is an executable string.

You can return a script, which causes ExtendScript to run the returned string as a JavaScript and to return from the function call with whatever the evaluation of the string returned. The field is string, and if you want ExtendScript to release a returned memory pointer, implement FreeMem().

Definition at line 149 of file SoSharedLibDefs.h.

Referenced by createArray(), makeArray(), and myScript().

#define kTypeString   4

A string value.

If you provide a string value, define the entry point FreeMem() in your DLL so ExtendScript can free your memory after use. Strings are supposed to be encoded in UTF-8 and to be null-terminated. The field is string, and if you want ExtendScript to release a returned memory pointer, implement FreeMem().

Definition at line 128 of file SoSharedLibDefs.h.

Referenced by acceptBoolean(), appendString(), built(), objectCall(), objectFinalize(), objectGet(), objectPut(), objectToString(), objectValueOf(), paramAny(), paramString(), and stringize().

#define kTypeUInteger   124

An unsigned integer value is an unsigned 32-bit quantity.

The field is intval.

Definition at line 142 of file SoSharedLibDefs.h.

Referenced by paramAny(), paramUInt32(), and stringize().

#define kTypeUndefined   0

The possible VariantData data types.

Undefined means that this value is not defined. ExtendScript passes this value in if an argument is supplied as "undefined". If a function should not return any value, the return value is Undefined as well. The return value for a function is always preset to Undefined.

Definition at line 114 of file SoSharedLibDefs.h.

Referenced by objectCall(), paramAny(), paramBool(), paramFloat64(), paramInt32(), paramString(), paramUInt32(), and stringize().


Typedef Documentation

typedef signed long ESerror_t

Definition at line 188 of file SoSharedLibDefs.h.

typedef long(* ESFunction)(TaggedData *argv, long argc, TaggedData *retval)

All functions need to be coded in the same way, following the function definition below.

ExtendScript passes in an array of arguments as VariantData, and supplies a VariantData element preset to Undefined for the return value. You should return any error code. If the function suceeds, the return value is kESErrOK.

Definition at line 162 of file SoSharedLibDefs.h.

typedef struct TaggedData_s TaggedData

Definition at line 105 of file SoSharedLibDefs.h.

Contents Files
Adobe Solutions Network
 
Copyright © 2010 Adobe Systems Incorporated. All rights reserved.
Terms of Use Online Privacy Policy Adobe and accessibility Avoid software piracy Permissions and Trademarks