bond-0.4.0.2: Bond schema compiler and code generator

Copyright(c) Microsoft
LicenseMIT
Maintaineradamsap@microsoft.com
Stabilityprovisional
Portabilityportable
Safe HaskellSafe
LanguageHaskell98

Language.Bond.Syntax.Types

Contents

Description

A suite of types describing the abstract syntax tree of the Bond schema definition language.

Synopsis

Schema definition file

data Bond Source

The top level type representing the Bond schema definition abstract syntax tree.

type QualifiedName = [String] Source

Represents fully qualified name

data Import Source

Import declaration.

Constructors

Import FilePath 

Declarations

data Default Source

Default value of a field.

Constructors

DefaultBool Bool 
DefaultInteger Integer 
DefaultFloat Double 
DefaultString String 
DefaultEnum String

name of an enum Constant

DefaultNothing

explicitly specified default value of nothing

data Modifier Source

Specifies whether a field is required or optional.

Constructors

Optional

field is optional and may be omitted during serialization

Required

field is required, deserialization will fail if it is missing

RequiredOptional

deserialization will not fail if the field is missing but it can't be omitted during serialization

data Constant Source

Definition of an Enum constant.

Constructors

Constant 

Types

data Type Source

Type in the Bond type system

Constructors

BT_Int8 
BT_Int16 
BT_Int32 
BT_Int64 
BT_UInt8 
BT_UInt16 
BT_UInt32 
BT_UInt64 
BT_Float 
BT_Double 
BT_Bool 
BT_String 
BT_WString 
BT_MetaName 
BT_MetaFullName 
BT_Blob 
BT_Maybe Type

type for fields with the default value of nothing

BT_List Type 
BT_Vector Type 
BT_Nullable Type 
BT_Set Type 
BT_Map Type Type 
BT_Bonded Type 
BT_IntTypeArg Int

an integer argument in an instance of a generic type Alias

BT_TypeParam TypeParam

type parameter of a generic Struct or Alias declaration

BT_UserDefined Declaration [Type]

user defined type or an instance of a generic type with the specified type arguments

data TypeParam Source

Type parameter of a generic Struct or type Alias

data Constraint Source

Constraint on a TypeParam.

Constructors

Value

the type parameter allows only value types

Metadata

data Attribute Source

Attribute for attaching user defined metadata to a Declaration or a Field

Constructors

Attribute 

Deprecated

data Language Source

Language annotation for namespaces. Note that language-specific namespaces are only supported for backward compatibility and are not recommended.

Constructors

Cpp 
Cs 
Java