Class FtpStateMachine<TStatus>.Transition
A class representing a transition.
Inherited Members
Namespace: FubarDev.FtpServer
Assembly: FubarDev.FtpServer.Abstractions.dll
Syntax
protected class Transition
  Constructors
| Improve this Doc View SourceTransition(TStatus, TStatus, String, SecurityActionResult)
Initializes a new instance of the FtpStateMachine<TStatus>.Transition class.
Declaration
public Transition(TStatus source, TStatus target, string command, SecurityActionResult resultCode)
  Parameters
| Type | Name | Description | 
|---|---|---|
| TStatus | source | The source status.  | 
      
| TStatus | target | The target status.  | 
      
| String | command | The trigger command.  | 
      
| SecurityActionResult | resultCode | The expected FTP code.  | 
      
Transition(TStatus, TStatus, String, Func<Int32, Boolean>)
Initializes a new instance of the FtpStateMachine<TStatus>.Transition class.
Declaration
public Transition(TStatus source, TStatus target, string command, Func<int, bool> isCodeMatch)
  Parameters
| Type | Name | Description | 
|---|---|---|
| TStatus | source | The source status.  | 
      
| TStatus | target | The target status.  | 
      
| String | command | The trigger command.  | 
      
| Func<Int32, Boolean> | isCodeMatch | A function to test if the code triggers this transition.  | 
      
Transition(TStatus, TStatus, String, Int32)
Initializes a new instance of the FtpStateMachine<TStatus>.Transition class.
Declaration
public Transition(TStatus source, TStatus target, string command, int hundredsRange)
  Parameters
| Type | Name | Description | 
|---|---|---|
| TStatus | source | The source status.  | 
      
| TStatus | target | The target status.  | 
      
| String | command | The trigger command.  | 
      
| Int32 | hundredsRange | The hundreds range.  | 
      
Remarks
The hundredsRange is multiplied by 100 to get the FTP code range.
Properties
| Improve this Doc View SourceSource
Gets the source status.
Declaration
public TStatus Source { get; }
  Property Value
| Type | Description | 
|---|---|
| TStatus | 
Target
Gets the target status.
Declaration
public TStatus Target { get; }
  Property Value
| Type | Description | 
|---|---|
| TStatus | 
Methods
| Improve this Doc View SourceIsMatch(String)
Returns true when this transition might be triggered by the given command.
Declaration
public bool IsMatch(string command)
  Parameters
| Type | Name | Description | 
|---|---|---|
| String | command | The command to test for.  | 
      
Returns
| Type | Description | 
|---|---|
| Boolean | true when this transition might be triggered by the given   | 
      
IsMatch(String, Int32)
Returns true when this transition will be triggered by the given command and code.
Declaration
public bool IsMatch(string command, int code)
  Parameters
| Type | Name | Description | 
|---|---|---|
| String | command | The command to test for.  | 
      
| Int32 | code | The code to test for.  | 
      
Returns
| Type | Description | 
|---|---|
| Boolean | true when this transition will be triggered by the given   |