Mono.CompilerServices.SymbolWriter.MonoSymbolFile.FindSource C# (CSharp) Method

FindSource() public method

public FindSource ( string file_name ) : int
file_name string
return int
        public int FindSource(string file_name)
        {
            if (reader == null)
                throw new InvalidOperationException ();

            lock (this) {
                if (source_name_hash == null) {
                    source_name_hash = new Dictionary<string, int> ();

                    for (int i = 0; i < ot.SourceCount; i++) {
                        SourceFileEntry source = GetSourceFile (i + 1);
                        source_name_hash.Add (source.FileName, i);
                    }
                }

                int value;
                if (!source_name_hash.TryGetValue (file_name, out value))
                    return -1;
                return value;
            }
        }