Constants

 

 

 

 

The following tables provide information on the most significant constants in the Aspen API.

 

Some of these constants have use in more than one context.

General Constants

Constant

Meaning

Value

ASPEN_YES

Yes, or true

1

ASPEN_NO

No, or false

0

ASPEN_ERROR

Error

(-1)

ASPEN_NONE

Zero

((void *)0)

ASPEN_NO_NUM

No price

((long)0x80000002)

 

The maximum possible positive value that an ASPEN_PRICE field can contain is defined by the constant ASPEN_MAX_NUM. The minimum negative value is set by the constant ASPEN_MIN_NUM. A special value, ASPEN_NO_NUM, is also used when the price field must indicate that there is no price value available. Signed comparisons must be used when comparing price values. Numerically speaking, ASPEN_NO_NUM is less than ASPEN_MIN_NUM. There are no values whatsoever greater than the defined maximum.

 

Constant

Meaning

Value

ASPEN_MAX_TIME

Maximum value storable in a ASPEN_TIME variable

0x7FFFFFFFL

ASPEN_MAX_VOLUME

Maximum value storable in a ASPEN_VOLUME variable

0x7FFFFFFFL

ASPEN_REAL_TIME

ASPEN_NO_NUM

ASPEN_NO_NUM

ASPEN_MAX_BARS

Maximum number of bars in GetBarHistory request

256

ASPEN_MAX_TICKS

Maximum number of bars in GetTickHistory request

256

Networking

Constant

Meaning

Value

ASPEN_IPX

IPX

(Not supported.) 0

ASPEN_INET

TCP/IP

1

ASPEN_MAX_NETADDRESS

Maximum length of a server address (DNS resolved name)

128

Price Quanta

Price quanta are defined with a base, binary or decimal.

 

Constant

Meaning

Value

ASPEN_BINARY

The base of an Aspen quantum is binary.

1

ASPEN_DECIMAL

The base of an Aspen quantum is decimal.

0

Trading Day

The number of minutes in 24 hours.

 

Constant

Meaning

Value

ASPEN_DAY

Number of minutes in a trading day.

1440

ASPEN_MAX_TRADING_SESSIONS

Maximum number of trading sessions a financial instrument may trade in one day.

4

Instruments

The maximum length of a financial instrument's symbol and description.

 

Constant

Meaning

Value

ASPEN_SYMBOL_SIZE

Maximum length of a financial instrument symbol.

20

ASPEN_SYMDESC_SIZE

Maximum length of a financial instrument description.

40

ASPEN_LABEL_SIZE

Maximum length of a financial instrument label.

16

Text Length

Constant

Meaning

Value

ASPEN_MAX_TEXTLENGTH

The maximum length of a textual string.

52

Data Feeds

The supported data feeds.

 

Constant

Meaning

Value

ASPEN_DF_UNKNOWN

The Server's source of data is probably an experimental or synthetic feed and has not yet been assigned a permanent ID.

0

ASPEN_DF_SIGNAL

DBC Signal

2

ASPEN_DF_REUTERS

Reuters data feeds.

3

ASPEN_DF_COMSTOCK

S&P ComStock

6

ASPEN_DF_DTN

DTN

8

ASPEN_DF_BONNEVILLE

Bonneville Market Information

9

ASPEN_DF_BRIDGE_BEQ

BridgeFeed

14

Instrument Types

Types of financial instruments.

 

Constant

Meaning

Value

ASPEN_IT_UNKNOWN

Unknown to this API.

0

ASPEN_IT_FUTURE

Futures contract.

1

ASPEN_IT_STOCK

Stock.

2

ASPEN_IT_FOREX

Foreign exchange instrument.

3

ASPEN_IT_TREASURY

US Treasury Cash.

4

ASPEN_IT_MORTGAGE

Mortgage backed security.

5

ASPEN_IT_INDEX

Indices or statistical values.

6

ASPEN_IT_CORP_BOND

Corporate bond.

7

ASPEN_IT_MUTUAL_FUND

Mutual fund.

8

ASPEN_IT_MONEY_MARKET

Money Market fund.

9

ASPEN_IT_BASKET

Basket of securities.

10

ASPEN_IT_CASH_SPOT

Cash or spot commodity.

11

ASPEN_IT_SPREAD

Spreads on futures or options.

12

ASPEN_IT_MUNI_BOND

Municipal bond.

13

more...?

 

 

Exchanges

Constant

Meaning

Value

ASPEN_MAX_XCHG_LENGTH

Length of exchange abbreviation.

16

ASPEN_MAX_XCHG_DESCRIPTION

 

Maximum length of exchange description.

104

Regional Exchanges

List of regional exchanges (exchanges from which stock (instrument type 2) trades may originate).

 

Constant

Meaning

Value

ASPEN_RX_DEFAULT

Unknown

0

ASPEN_RX_BOSTON

Boston

1

ASPEN_RX_CINCINNATI

Cincinnati

2

ASPEN_RX_MIDWEST

Midwest

3

ASPEN_RX_PACIFIC

Pacific

4

ASPEN_RX_NASDAQ

NASDAQ

5

ASPEN_RX_PHILADELPHIA

Philadelphia

6

ASPEN_RX_INSTINET

Internet

7

ASPEN_RX_NYSE

New York Stock Exchange

8

ASPEN_RX_AMEX

American Stock Exchange

9

Bates

Tick types or bate codes (see also, ASPEN_BATE).

 

Constant

Meaning

Value

ASPEN_BATE_REFRESH

informational only; not used with historical ticks.

0

ASPEN_BATE_TRADE

Tick is a trade.

1

ASPEN_BATE_BID

Tick is a bid.

2

ASPEN_BATE_ASK

Tick is an ask.

3

ASPEN_BATE_SETTLE

Tick is a settlement price.

4

ASPEN_BATE_OPEN

Tick is an open price.

5

ASPEN_BATE_CLOSE

Tick is a close price.

6

ASPEN_BATE_UNKNOWN

Tick is unknown to this API.

7

Symbol Operations

Symbol event notices.

 

Constant

Meaning

Value

ASPEN_SYM_ADD

Add symbol to the Server database.

0

ASPEN_SYM_DEL

Delete symbol from Server database.

1

Security Authentications

User name and password max length.

 

Constant

Meaning

Value

ASPEN_USER_NAME_SIZE

Maximum size of a user name.

128

ASPEN_PASSWORD_SIZE

Maximum size of a password.

12

Holidays

Constant

Meaning

Value

ASPEN_MAX_HOLNAME

Maximum length of holiday list name.

20

News

Constant

Meaning

Value

ASPEN_MAX_NEWSTITLE_LENGTH

Maximum length of a news title.

82

QM_HEADLINE

Specifies a query of all news headlines.

0x02

QM_STANDARD

Specifies a query of headlines within a particular news category.

0x00

ASPEN_MAX_STORY_HANDLES

 Maximum number of headlines per query.

15

 

Depth of Market

Constant

Meaning

Value

MAX_DOM_LENGTH

Maximum length of array used to track bid ask depth of market for Level II analysis.

30

 

 

©2006 Aspen Research Group, Ltd. All rights reserved. Terms of Use.