StrDict::Load( FILE * )

Unmarshals the StrDict from a file.

Virtual?

No

 

Class

StrDict

 

Arguments

FILE *i

the file to load from

Returns

int

always equals 1

Notes

Load() loads a StrDict from a file previously created by Save().

Example

The following example "loads" a StrDict by reading it from stdin.

MyStrDict sd;
ClientUser ui;

sd.Load( stdin );
ui.OutputStat( &sd );

Given a marshaled StrDict on stdin, the code produces the following output:

> cat marshaled.strdict

depotFile=//depot/file.c
clientFile=c:\test\depot\file.c
headAction=edit
headType=text
headTime=1020067607
headRev=4
headChange=2042
headModTime 1020067484
func=client-FstatInfo

> a.out < marshaled.strdict

... depotFile //depot/file.c
... clientFile clientFile=c:\test\depot\file.c
... headAction edit
... headType text
... headTime 1020067607
... headRev 4
... headChange 2042
... headModTime 1020067484