Amazon.Util.Internal.InternalSDKUtils.GetMonoRuntimeVersion C# (CSharp) 메소드

GetMonoRuntimeVersion() 공개 정적인 메소드

public static GetMonoRuntimeVersion ( ) : string
리턴 string
        public static string GetMonoRuntimeVersion()
        {
            Type type = Type.GetType("Mono.Runtime");
            if (type != null)
            {
                MethodInfo displayName = type.GetMethod("GetDisplayName");
                if (displayName != null)
                {
                    var version = (string)displayName.Invoke(null, null);
                    // Replace "/" from the version string as it's a
                    // seperator in the user agent format
                    version = version.Replace("/", ":").Replace(" ",string.Empty);
                    return "Mono/" + version;
                }
            }
            return UnknownMonoVersion;
        }