C# Class WebApplications.Utilities.PowerShell.NuSpecEditor

Mostra file Open project: webappsuk/CoreLibraries

Private Properties

Property Type Description
GetMetadata string
SetMetadata void

Public Methods

Method Description
EnsureDependency ( NuSpecDependency dependency ) : void

Ensures the dependency is added if not present.

EnsureDependency ( string dependency ) : void

Ensures the dependency is added if not present.

NuSpecEditor ( [ path ) : System

Initializes a new instance of the NuSpecEditor class.

RemoveDependencies ( Regex idregex ) : void

Removes all dependencies matching the regex.

RemoveDependencies ( string ids ) : void

Removes all dependencies matching the supplied ids.

Save ( ) : void

Saves this instance if their are changes.

Private Methods

Method Description
GetMetadata ( [ name ) : string
SetMetadata ( [ name, [ value ) : void

Sets the metadata property with the specified name.

Method Details

EnsureDependency() public method

Ensures the dependency is added if not present.
public EnsureDependency ( NuSpecDependency dependency ) : void
dependency NuSpecDependency The dependency.
return void

EnsureDependency() public method

Ensures the dependency is added if not present.
public EnsureDependency ( string dependency ) : void
dependency string The dependency.
return void

NuSpecEditor() public method

Initializes a new instance of the NuSpecEditor class.
public NuSpecEditor ( [ path ) : System
path [ The nuget package specification file.
return System

RemoveDependencies() public method

Removes all dependencies matching the regex.
public RemoveDependencies ( Regex idregex ) : void
idregex System.Text.RegularExpressions.Regex The regex to match the id against.
return void

RemoveDependencies() public method

Removes all dependencies matching the supplied ids.
public RemoveDependencies ( string ids ) : void
ids string The ids (multiple ids can be separated with any of ',;|').
return void

Save() public method

Saves this instance if their are changes.
public Save ( ) : void
return void