Ejemplo n.º 1
0
        private void InitializeParsedGridReference(SheetReference @ref, string s)
        {
            ReferenceParseProperties parseProps = SheetReference.CreateParseProperties(s);

            @ref.SetEngine(_owner);
            @ref.ProcessParseProperties(parseProps, _owner);
            @ref.Validate();
            @ref.ComputeHashCode();
        }
Ejemplo n.º 2
0
        public override void ProcessParseProperties(ReferenceParseProperties props, FormulaEngine engine)
        {
            ISheet sheet = props.SheetName == null ? engine.Sheets.ActiveSheet :
                           engine.Sheets.GetSheetByName(props.SheetName);

            _sheetName = props.SheetName;
            if (sheet != null)
            {
                Sheet = sheet;
            }
        }
Ejemplo n.º 3
0
        public static ReferenceParseProperties CreateParseProperties(string s)
        {
            var props = new ReferenceParseProperties();

            int bangIndex = s.IndexOf('!');

            if (bangIndex != -1)
            {
                props.SheetName = s.Substring(0, bangIndex);
            }

            return(props);
        }
Ejemplo n.º 4
0
        private void ProcessParseInfos(ReferenceParseInfo[] infos)
        {
            int len = infos.Length;

            _rawReferences       = new Reference[len];
            _referenceProperties = new ReferenceProperties[len];

            for (int i = 0; i < len; i++)
            {
                ReferenceParseInfo       info  = infos[i];
                Reference                @ref  = info.Target;
                ReferenceParseProperties props = info.ParseProperties;
                @ref.SetEngine(Engine);
                @ref.ProcessParseProperties(props, Engine);
                _rawReferences[i]       = @ref;
                _referenceProperties[i] = info.Properties;
            }
        }
Ejemplo n.º 5
0
 public virtual void ProcessParseProperties(ReferenceParseProperties props, FormulaEngine engine)
 {
 }