Ejemplo n.º 1
0
            Block ResolveType(String selector, out bool isGroup)
            {
                var tokens     = PROGRAM.ParseTokens(selector);
                var parameters = PROGRAM.ParseCommandParameters(tokens);
                var blockType  = findLast <BlockTypeCommandParameter>(parameters);

                isGroup = findLast <GroupCommandParameter>(parameters) != null;
                if (blockType == null)
                {
                    throw new Exception("Cannot parse block type from selector: " + selector);
                }
                return(blockType.value);
            }