protobuf

package
v0.6.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 12, 2018 License: Apache-2.0 Imports: 4 Imported by: 0

README

Protobuf

##Construct build environment

  1. Install g++ g++ version should be no less than 7. For ubuntu operator system, please follow these steps:

    sudo add-apt-repository ppa:ubuntu-toolchain-r/test
    sudo apt update
    sudo apt install g++-7 -y
    
  2. Install Protocol Buffers Library Please follow this document to install protocol buffers library.

  3. Install libjsoncpp-dev

    sudo apt-get install libjsoncpp-dev
    sudo ln -s /usr/include/jsoncpp/json/ /usr/include/json
    

##Build

  1. Build cpp to library:
    make build
    
  2. Clean the library
    make clean
    

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvertProtoToJson

func ConvertProtoToJson(protoPath, protoName, messageName string, protoBufByte []byte) (string, error)

func SerializeJsonToProto

func SerializeJsonToProto(protoPath, protoName, messageName string, jsonString string) ([]byte, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL