the section called “Defining Input, Output.” shows you an example on how to use the types when defining the function.

Predefined types.

XINS has some integrated types which facilitate the use of input and output parameters with the implementation.

Table 4. XINS integrated types

typeJava representationExample
_textjava.lang.Stringhello world
_booleanbooleantrue
_int8byte25
_int16short2004
_int32int15
_int64long654654132135544566
_float32float25.6
_float64double3.14159
_dateorg.xins.common.types.standard.Date.Value20040514
_timestamporg.xins.common.types.standard.Timestamp.Value20040514115930
_propertyorg.xins.common.collections.PropertyReaderupgrade%3Dtrue%26surname%3Dde%2BHaan
_listorg.xins.common.types.standard.List.Valueitem1%26item2%26item1
_setorg.xins.common.types.standard.Set.Valueitem3%26item1%26item2
_base64byte[]aGVsbG8=
_hexbyte[]546573746f
_urlStringhttp://www.google.com
_descriptororg.xins.common.service.Descriptor

descriptor=group, random, target1, target2

descriptor.target1=service, http://127.0.0.1:8080/my-project/, 8000

descriptor.target2=service, http://192.168.0.1:8080/my-project/, 8000


You can find an example using all these types in the function demo\xins-project\apis\allinone\spec\SimpleTypes.fnc.

Defined types

As seen in the section called “Defining Input, Output.”, it's also possible to define your own type. Here is a list of the possible types to define in XINS:

You can find an example using some of these types in the function demo\xins-project\apis\allinone\spec\DefinedTypes.fnc.

Shared types

If you have more than one API, you may want to reuse types defined in other APIs (for example EMail.typ, Account.typ, LastName.typ, ...). Instead of copying the file to the new API, you can also point to this type. This is done by using <api name>/<type name> in api.xml and in the function(s) specification.

For example:

  <type name="petstore/EMail"/>
  <param name="outputEMail" required="false" type="petstore/EMail">
    <description>An example of output shared type.</description>
  </param>