Home Notices Documents Classes Download Others Rice
Classes  >  preference  >  GetType(string)
preference class : GetType(string) method

Description

Obtains type of the entry specified by argument as string.

Syntax

preferenceInstance.GetType(string prefName)

Arguments

ClassNameDescription
stringprefNameA preference name.

Return value

ClassDescription
stringA string that represents type of the entry.

Sample code

1:

preference pref = new preference();

2:

pref.Set("some.preference.entry", "some value"); // It makes new entry;

3:

string type = pref.GetType("some.preference.entry"); // The type is "string".

Notes

The "int", "bool", or "string" will be returned.

If the entry is not exist, an RtypeException will be thrown.

Links for reference

None.

Copyright © Rice All rights reserved.