/**
 * @brief Contains datatypes most commonly used in sdr projects. 
 * @note Besides of EndpointIndex, please use proto base types when 
 *       creating your own messages to avoid unneccessary stacking. 
 *       Messages listed here are intended for simple get/set functions
 */

syntax = "proto3";
package sdr.datatypes;

message EndpointIndex {
    oneof ep_ident {
        uint32 value = 1;
        string name = 2;
    }
}

message Empty  {}
message Bool   { bool value = 1;   }
message Int    { int32 value = 1;  }
message LInt   { int64 value = 1;  }
message UInt   { uint32 value = 1; }
message LUInt  { uint64 value = 1; }
message Float  { float value = 1;  }
message Double { double value = 1; }
message String { string value = 1; }

message IndexedBool {
    EndpointIndex index = 1;
    bool value = 2;
}
message IndexedInt {
    EndpointIndex index = 1;
    int32 value = 2;
}
message IndexedLInt {
    EndpointIndex index = 1;
    int64 value = 2;
}
message IndexedUInt {
    EndpointIndex index = 1;
    uint32 value = 2;
}
message IndexedLUInt {
    EndpointIndex index = 1;
    uint64 value = 2;
}
message IndexedFloat {
    EndpointIndex index = 1;
    float value = 2;
}
message IndexedDouble {
    EndpointIndex index = 1;
    double value = 2;
}
message IndexedString {
    EndpointIndex index = 1;
    string value = 2;
}