uses internal formats to represent data entities that it can process. All processing agents (for instance, Analysis and Aggregation) work with these internal formats.
A syntax for the internal format is declared as follows:
Code Block |
---|
internal <name> [: (<class specifications> | <format inheritance>) ] { <field_type> <field_name> [:optional] ; ... }; |
The field types may be any of the following:
Field Type | Description |
---|---|
| Any type. |
| Big integer. |
| Big decimal. |
| Boolean. |
| Byte array. |
| Integer type (8-bit signed). |
| Integer type (16-bit unsigned). |
| Integer type (16-bit signed). |
| Integer type (32-bit signed). |
| Integer type (64-bit signed). |
| Float type (32-bit). |
| Float type (64-bit). |
| Date type, with capability to hold date parts, time parts, or both. |
| A set of bits. |
| An IP address. |
| An instance of any other internal (all internal are drudr instances). |
| String. |
The field_type
can also be any other internal or list type that is defined in either the same ultra file or in another. See the example below.
Info | |||||
---|---|---|---|---|---|
title | Example - Internal formatsCase 1:
Case 2:
|
...
Code Block |
---|
list< ElementType > |
Where ElementType
can be any of the previous, including an internal format identifier, or another list type.
Info | ||
---|---|---|
Example - List type
|
It is also possible to specify a field as optional:
Info | ||
---|---|---|
Example - Specifying a field as optional
|
...
Code Block |
---|
map< ElementType, ElementType > |
Info | ||
---|---|---|
Example - Declaring a map field
|
Internal formats can also be automatically generated from in_map
definitions. For further information, see target_internal specification in In-maps.
Class Specifications
All internal formats are compiled into Java classes. It is possible to specify additional interfaces for the class to implement:
Info | ||
---|---|---|
Example - Class specifications
|
However, this requires that Interface1
and Interface2
only declare methods that are later generated by Ultra when it creates the Java class. For further information about methods and types for UDR type methods, see the /wiki/spaces/MD82/pages/3779155.
Format Inheritance
It is possible to You can use alternative base UDR definitions for the generated Ultra classes by use of using the extends_class
or extends
option, but all UDR types cannot be used as an extension base. Except for UDR types defined in Ultra, only some specific agent UDRs are extendible, and “session” UDR types can not be used.
extends_class
is used by some agents (for instance, the HTTP agent) for better processing support.
Info | ||
---|---|---|
Example - extends_class
|
The extends
option lets a format inherit fields defined in an ancestor.
Info | ||
---|---|---|
Example - extends
|
Multiple inheritances is not supported. That is, meaning you can only use the extends
or extends_class
option once in the definition of an internal format.
...