Unosquare
    Show / Hide Table of Contents

    Class SwanRuntime

    Provides utility methods to retrieve information about the current application.

    Inheritance
    Object
    SwanRuntime
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Swan
    Syntax
    public static class SwanRuntime

    Properties

    CompanyName

    Gets the name of the company.

    Declaration
    public static string CompanyName { get; }
    Property Value
    Type Description
    String

    The name of the company.

    EntryAssembly

    Gets the assembly that started the application.

    Declaration
    public static Assembly EntryAssembly { get; }
    Property Value
    Type Description
    Assembly

    The entry assembly.

    EntryAssemblyDirectory

    Gets the full path to the folder containing the assembly that started the application.

    Declaration
    public static string EntryAssemblyDirectory { get; }
    Property Value
    Type Description
    String

    The entry assembly directory.

    EntryAssemblyName

    Gets the name of the entry assembly.

    Declaration
    public static AssemblyName EntryAssemblyName { get; }
    Property Value
    Type Description
    AssemblyName

    The name of the entry assembly.

    EntryAssemblyVersion

    Gets the entry assembly version.

    Declaration
    public static Version EntryAssemblyVersion { get; }
    Property Value
    Type Description
    Version

    IsTheOnlyInstance

    Checks if this application (including version number) is the only instance currently running.

    Declaration
    public static bool IsTheOnlyInstance { get; }
    Property Value
    Type Description
    Boolean

    true if this instance is the only instance; otherwise, false.

    IsUsingMonoRuntime

    Gets a value indicating whether this application instance is using the MONO runtime.

    Declaration
    public static bool IsUsingMonoRuntime { get; }
    Property Value
    Type Description
    Boolean

    true if this instance is using MONO runtime; otherwise, false.

    LocalStoragePath

    Gets a local storage path with a version.

    Declaration
    public static string LocalStoragePath { get; }
    Property Value
    Type Description
    String

    The local storage path.

    OS

    Gets the current Operating System.

    Declaration
    public static OperatingSystem OS { get; }
    Property Value
    Type Description
    OperatingSystem

    The os.

    ProductName

    Gets the name of the product.

    Declaration
    public static string ProductName { get; }
    Property Value
    Type Description
    String

    The name of the product.

    ProductTrademark

    Gets the trademark.

    Declaration
    public static string ProductTrademark { get; }
    Property Value
    Type Description
    String

    The product trademark.

    Methods

    GetDesktopFilePath(String)

    Build a full path pointing to the current user's desktop with the given filename.

    Declaration
    public static string GetDesktopFilePath(string filename)
    Parameters
    Type Name Description
    String filename

    The filename.

    Returns
    Type Description
    String

    The fully qualified location of path, such as "C:\MyFile.txt".

    Comments

    Back to top Copyright © 2017-2019 Unosquare