Show / Hide Table of Contents

    Class PasvListenerFactory

    Creates TcpListeners for use with PASV commands.

    Inheritance
    Object
    PasvListenerFactory
    Implements
    IPasvListenerFactory
    Inherited Members
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Object.ReferenceEquals(Object, Object)
    Object.ToString()
    Namespace: FubarDev.FtpServer
    Assembly: FubarDev.FtpServer.dll
    Syntax
    public class PasvListenerFactory : IPasvListenerFactory

    Constructors

    | Improve this Doc View Source

    PasvListenerFactory(IPasvAddressResolver, Nullable<ILogger<PasvListenerFactory>>)

    Initializes a new instance of the PasvListenerFactory class.

    Declaration
    public PasvListenerFactory(IPasvAddressResolver addressResolver, ILogger<PasvListenerFactory>? logger = default(ILogger<PasvListenerFactory>? ))
    Parameters
    Type Name Description
    IPasvAddressResolver addressResolver

    The address resolver for PASV/EPSV.

    Nullable<ILogger<PasvListenerFactory>> logger

    Logger instance.

    Methods

    | Improve this Doc View Source

    CreateTcpListenerAsync(IFtpConnection, Nullable<AddressFamily>, Int32, CancellationToken)

    Create a new TcpListener for the given connection.

    Declaration
    public Task<IPasvListener> CreateTcpListenerAsync(IFtpConnection connection, AddressFamily? addressFamily, int port, CancellationToken cancellationToken)
    Parameters
    Type Name Description
    IFtpConnection connection

    connection on which to create the tcp listener.

    Nullable<AddressFamily> addressFamily

    The address family for the address to be selected.

    Int32 port

    listen on the given port, or 0 for any port.

    CancellationToken cancellationToken

    The cancellation token.

    Returns
    Type Description
    Task<IPasvListener>

    A TcpListener.

    Exceptions
    Type Condition
    SocketException

    Network error, such as no free port.

    ArgumentOutOfRangeException

    The chosen port was not within the configured range of ports.

    Implements

    IPasvListenerFactory
    • Improve this Doc
    • View Source
    Back to top
    Copyright © 2018 Fubar Development Junker
    Generated by DocFX
    Creative Commons License
    FluentMigrator Documentation by FluentMigrator Project is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.