newspeoplefor developersdocumentationdownloads

nPrefServer Script Interface

nprefserver:

Super Class:

C++ Class:

Info

Manages persistent information between application invocations.

Commands:


setcompanyname

Command Input:
s(CompanyName)
Command Output:
v
Command Description:
Set company name for this application. This is used together with the application name to form an unique place where information is stored.

getcompanyname

Command Input:
Command Output:
v s(CompanyName)
Command Description:
Get company name for this application.

setapplicationname

Command Input:
s(ApplicationName)
Command Output:
v
Command Description:
Set the application name.

getapplicationname

Command Input:
v
Command Output:
s(ApplicationName)
Command Description:
Get application name.

open

Command Input:
v
Command Output:
b(Success)
Command Description:
Opens the preferences server. A valid company and application name must be set before opening the server.

close

Command Input:
v
Command Output:
v
Command Description:
Closes the preferences server.

isopen

Command Input:
v
Command Output:
b(OpenFlag)
Command Description:
Return true if the prefs server is open.

keyexists

Command Input:
v
Command Output:
b(KeyExists)
Command Description:
Returns true if a key of that name exists.

writestring

Command Input:
s(Key), s(Value)
Command Output:
b(Success)
Command Description:
Write a persistent string.

writeint

Command Input:
s(Key), i(Value)
Command Output:
b(Success)
Command Description:
Write a persistent int value.

writefloat

Command Input:
s(Key), f(Value)
Command Output:
b(Success)
Command Description:
Write a persistent float value.

writebool

Command Input:
s(Key), b(Value)
Command Output:
b(Success)
Command Description:
Write a persistent bool value.

writevector4

Command Input:
s(Key), ffff(xyzw)
Command Output:
b(Success)
Command Description:
Write a persistent vector4 value.

writevector3

Command Input:
s(Key), fff(xyz)
Command Output:
b(Success)
Command Description:
Write a persistent vector3 value.

readstring

Command Input:
s(Key)
Command Output:
s(Value)
Command Description:
Read a persistent string value.

readint

Command Input:
s(Key)
Command Output:
i(Value)
Command Description:
Read a persistent int value.

readfloat

Command Input:
s(Key)
Command Output:
f(Value)
Command Description:
Read a persistent float value.

readbool

Command Input:
s(Key)
Command Output:
b(Value)
Command Description:
Read a persistent bool value.

readvector4

Command Input:
s(Key)
Command Output:
ffff(xyzw)
Command Description:
Read a persistent vector4 value.

readvector3

Command Input:
s(Key)
Command Output:
fff(xyz)
Command Description:
Read a persistent vector3 value.

Copyright © 1999-2005 by the contributing authors. Ideas, requests, problems: Send feedback.