C# Class NCldr.ProtobufFileDataSource

ProtobufFileDataSource loads/saves the raw NCLDR data from an NCldr Protocol Buffers binary data file
This class requires the protobuf-net library from https://code.google.com/p/protobuf-net/. Set the ProtobufFileDataSource.NCldrDataPath property before calling Load
Inheritance: INCldrFileDataSource
Exibir arquivo Open project: GuySmithFerrier/NCLDR

Public Methods

Method Description
Exists ( ) : bool

Exists returns true if the NCldr data file exists

Load ( ) : INCldrData

Loads loads the raw data from the NCldr data file and returns an NCldrData object

Save ( INCldrData ncldrData ) : void

Save saves the NCldrData object to the NCldr data file

Private Methods

Method Description
AddProtobufType ( Type allTypes, Type type ) : void

Adds a default protobuf data contract to the protobuf runtime model

ProtobufFileDataSource ( ) : System

Initializes static members of the ProtobufFileDataSource class

Method Details

Exists() public method

Exists returns true if the NCldr data file exists
public Exists ( ) : bool
return bool

Load() public method

Loads loads the raw data from the NCldr data file and returns an NCldrData object
public Load ( ) : INCldrData
return INCldrData

Save() public method

Save saves the NCldrData object to the NCldr data file
public Save ( INCldrData ncldrData ) : void
ncldrData INCldrData The INCldrData object to save
return void