2014-03-14 14:13:41 -04:00
|
|
|
// Copyright 1998-2014 Epic Games, Inc. All Rights Reserved.
|
|
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Interface for network file servers.
|
|
|
|
|
*/
|
|
|
|
|
class INetworkFileServer
|
|
|
|
|
{
|
|
|
|
|
public:
|
2014-06-12 17:02:52 -04:00
|
|
|
/**
|
|
|
|
|
*
|
|
|
|
|
* Returns Whether the network server was able to successfully start or not.
|
|
|
|
|
*
|
|
|
|
|
* @return true on success, false otherwise.
|
|
|
|
|
*/
|
|
|
|
|
virtual bool IsItReadyToAcceptConnections(void) const = 0;
|
2014-06-12 23:22:18 -04:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Gets the list of local network addresses that the file server listens on.
|
|
|
|
|
*
|
|
|
|
|
* @param OutAddresses - Will hold the address list.
|
|
|
|
|
*
|
|
|
|
|
* @return true on success, false otherwise.
|
|
|
|
|
*/
|
2014-03-14 14:13:41 -04:00
|
|
|
virtual bool GetAddressList( TArray<TSharedPtr<FInternetAddr> >& OutAddresses ) const = 0;
|
|
|
|
|
|
2014-07-07 15:39:19 -04:00
|
|
|
/**
|
|
|
|
|
* Gets the list of local network addresses that the file server listens on.
|
|
|
|
|
*
|
|
|
|
|
* @param OutAddresses - Will hold the address list.
|
|
|
|
|
*
|
|
|
|
|
* @return true on success, false otherwise.
|
|
|
|
|
*/
|
|
|
|
|
virtual FString GetSupportedProtocol() const = 0;
|
|
|
|
|
|
2014-03-14 14:13:41 -04:00
|
|
|
/**
|
|
|
|
|
* Gets the number of active connections.
|
|
|
|
|
*
|
|
|
|
|
* @return The number of connections.
|
|
|
|
|
*/
|
2014-06-12 17:02:52 -04:00
|
|
|
virtual int32 NumConnections(void) const = 0;
|
2014-03-14 14:13:41 -04:00
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Shuts down the file server.
|
|
|
|
|
*/
|
2014-06-12 17:02:52 -04:00
|
|
|
virtual void Shutdown(void) = 0;
|
2014-03-14 14:13:41 -04:00
|
|
|
|
2014-06-12 23:22:18 -04:00
|
|
|
public:
|
|
|
|
|
|
2014-03-14 14:13:41 -04:00
|
|
|
/**
|
|
|
|
|
* Virtual destructor.
|
|
|
|
|
*/
|
2014-06-12 17:02:52 -04:00
|
|
|
virtual ~INetworkFileServer(void) { }
|
2014-03-14 14:13:41 -04:00
|
|
|
};
|