hydra-0.5.1: Type-aware transformations for data and programs
Safe HaskellSafe-Inferred
LanguageHaskell2010

Hydra.Langs.Protobuf.Proto3

Description

A model for Protocol Buffers v3 enum and message types, designed as a target for transformations.This model is loosely based on https://github.com/protocolbuffers/protobuf/blob/main/src/google/protobuf/type.proto, as well as the proto3 reference documentation

Synopsis

Documentation

data EnumValue Source #

Enum value definition

Constructors

EnumValue 

Fields

data Field Source #

A single field of a message type

Constructors

Field 

Fields

Instances

Instances details
Read Field Source # 
Instance details

Defined in Hydra.Langs.Protobuf.Proto3

Show Field Source # 
Instance details

Defined in Hydra.Langs.Protobuf.Proto3

Methods

showsPrec :: Int -> Field -> ShowS #

show :: Field -> String #

showList :: [Field] -> ShowS #

Eq Field Source # 
Instance details

Defined in Hydra.Langs.Protobuf.Proto3

Methods

(==) :: Field -> Field -> Bool #

(/=) :: Field -> Field -> Bool #

Ord Field Source # 
Instance details

Defined in Hydra.Langs.Protobuf.Proto3

Methods

compare :: Field -> Field -> Ordering #

(<) :: Field -> Field -> Bool #

(<=) :: Field -> Field -> Bool #

(>) :: Field -> Field -> Bool #

(>=) :: Field -> Field -> Bool #

max :: Field -> Field -> Field #

min :: Field -> Field -> Field #

data MessageDefinition Source #

A protocol buffer message type

Constructors

MessageDefinition 

Fields

data Option Source #

A protocol buffer option, which can be attached to a message, field, enumeration, etc

Constructors

Option 

Fields

  • optionName :: String

    The option's name. For protobuf built-in options (options defined in descriptor.proto), this is the short name. For example, `"map_entry"`. For custom options, it should be the fully-qualified name. For example, `"google.api.http"`.

  • optionValue :: Value

    The option's value

Instances

Instances details
Read Option Source # 
Instance details

Defined in Hydra.Langs.Protobuf.Proto3

Show Option Source # 
Instance details

Defined in Hydra.Langs.Protobuf.Proto3

Eq Option Source # 
Instance details

Defined in Hydra.Langs.Protobuf.Proto3

Methods

(==) :: Option -> Option -> Bool #

(/=) :: Option -> Option -> Bool #

Ord Option Source # 
Instance details

Defined in Hydra.Langs.Protobuf.Proto3

data ProtoFile Source #

A .proto file, usually containing one or more enum or message type definitions

newtype TypeName Source #

The local name of an enum type or message type

Constructors

TypeName 

Fields

data Value Source #

A scalar value

Instances

Instances details
Read Value Source # 
Instance details

Defined in Hydra.Langs.Protobuf.Proto3

Show Value Source # 
Instance details

Defined in Hydra.Langs.Protobuf.Proto3

Methods

showsPrec :: Int -> Value -> ShowS #

show :: Value -> String #

showList :: [Value] -> ShowS #

Eq Value Source # 
Instance details

Defined in Hydra.Langs.Protobuf.Proto3

Methods

(==) :: Value -> Value -> Bool #

(/=) :: Value -> Value -> Bool #

Ord Value Source # 
Instance details

Defined in Hydra.Langs.Protobuf.Proto3

Methods

compare :: Value -> Value -> Ordering #

(<) :: Value -> Value -> Bool #

(<=) :: Value -> Value -> Bool #

(>) :: Value -> Value -> Bool #

(>=) :: Value -> Value -> Bool #

max :: Value -> Value -> Value #

min :: Value -> Value -> Value #