C# Class Mckineap.Models.Context.Data.Preferences

Inheritance: FileObject
显示文件 Open project: loic-lavergne/mckineap Class Usage Examples

Protected Properties

Property Type Description
categories Collection
settings Collection

Public Methods

Method Description
GetCategoryFileFromName ( String category ) : String
GetSettingValue ( string category, string settingName ) : String
LoadDefaultPreferences ( ) : System.Boolean
LoadPreferences ( ) : System.Boolean

Loads the Preferences from the category files in the Project's Preferences path

Preferences ( string path ) : Mckineap.Utilities
PreferencesWorkspaceExists ( ) : System.Boolean

Checks if the Preferences workspace exists.

Reinitialize ( string fullPath ) : bool

Reinitializes the FileObject with specified path.
The other attributes are processed from the provided parameter.

SetCategories ( Collection newCategories ) : void
SetSettings ( Collection newSettings ) : void

Protected Methods

Method Description
CategoryFileIsValid ( String categoryFile ) : System.Boolean

Determines whether the file exists, is of type XML and is not empty.
This method doesn't ensure that the file data is correct.

CategoryFilesAreValid ( ) : System.Boolean

Checks if the category files exist, are of type XML and are not empty.

Method Details

CategoryFileIsValid() protected method

Determines whether the file exists, is of type XML and is not empty.
This method doesn't ensure that the file data is correct.
protected CategoryFileIsValid ( String categoryFile ) : System.Boolean
categoryFile String The file to check.
return System.Boolean

CategoryFilesAreValid() protected method

Checks if the category files exist, are of type XML and are not empty.
protected CategoryFilesAreValid ( ) : System.Boolean
return System.Boolean

GetCategoryFileFromName() public method

public GetCategoryFileFromName ( String category ) : String
category String
return String

GetSettingValue() public method

public GetSettingValue ( string category, string settingName ) : String
category string
settingName string
return String

LoadDefaultPreferences() public method

public LoadDefaultPreferences ( ) : System.Boolean
return System.Boolean

LoadPreferences() public method

Loads the Preferences from the category files in the Project's Preferences path
public LoadPreferences ( ) : System.Boolean
return System.Boolean

Preferences() public method

public Preferences ( string path ) : Mckineap.Utilities
path string
return Mckineap.Utilities

PreferencesWorkspaceExists() public method

Checks if the Preferences workspace exists.
public PreferencesWorkspaceExists ( ) : System.Boolean
return System.Boolean

Reinitialize() public method

Reinitializes the FileObject with specified path.
The other attributes are processed from the provided parameter.
public Reinitialize ( string fullPath ) : bool
fullPath string The full path of the file.
return bool

SetCategories() public method

public SetCategories ( Collection newCategories ) : void
newCategories Collection
return void

SetSettings() public method

public SetSettings ( Collection newSettings ) : void
newSettings Collection
return void

Property Details

categories protected_oe property

protected Collection categories
return Collection

settings protected_oe property

protected Collection settings
return Collection