Class CreateFacilityCommand
Command to create a new healthcare facility.
public class CreateFacilityCommand : AbstractCommand, ICommand
- Inheritance
-
CreateFacilityCommand
- Implements
- Inherited Members
Constructors
CreateFacilityCommand(string, string, string)
Initializes a new instance of the CreateFacilityCommand class.
public CreateFacilityCommand(string name, string address, string phone)
Parameters
namestringThe name of the new facility.
addressstringThe physical address of the new facility.
phonestringThe contact phone number for the new facility.
Fields
Key
The unique key for the CreateFacility command.
public const string Key = "createfacility"
Field Value
Properties
CommandKey
Gets the unique key identifier for this command type.
public override string CommandKey { get; }
Property Value
Description
Gets the description of what this command does.
public override string Description { get; }
Property Value
Methods
ExecuteCore(CommandParameters, SessionContext?)
Executes the core logic of the command.
protected override CommandResult ExecuteCore(CommandParameters parameters, SessionContext? session)
Parameters
parametersCommandParametersThe parameters for the command.
sessionSessionContextThe user session context.
Returns
- CommandResult
The result of the command execution.
GetRequiredPermission()
Gets the required permission to execute this command.
public override Permission? GetRequiredPermission()
Returns
- Permission?
The required permission.
ValidateParameters(CommandParameters)
Validates the parameters for the command.
protected override CommandValidationResult ValidateParameters(CommandParameters parameters)
Parameters
parametersCommandParametersThe parameters to validate.
Returns
- CommandValidationResult
The result of the validation.