Fan.Sys.SysInStream.dotnet C# (CSharp) Method

dotnet() public static method

Get a System.IO.Stream for the specified input stream.
public static dotnet ( InStream ins ) : Stream
ins InStream
return Stream
        public static Stream dotnet(InStream ins)
        {
            if (ins is SysInStream)
            return ((SysInStream)ins).inStream;
              else
            return new DotnetInputStream (ins);
        }

Usage Example

Example #1
0
        public static Pod load(InStream @in)
        {
            FPod fpod = null;

            try
            {
                fpod = new FPod(null, null);
                fpod.readFully(new ZipInputStream(SysInStream.dotnet(@in)));
            }
            catch (Exception e)
            {
                throw Err.make(e).val;
            }

            string name = fpod.m_podName;

            lock (m_podsByName)
            {
                // check for duplicate pod name
                if (m_podsByName[name] != null)
                {
                    throw Err.make("Duplicate pod name: " + name).val;
                }

                // create Pod and add to master table
                Pod pod = new Pod(fpod);
                m_podsByName[name] = pod; //new SoftReference(pod);
                return(pod);
            }
        }
All Usage Examples Of Fan.Sys.SysInStream::dotnet