Package sc.parser

Class FormattingParseNode

    • Constructor Detail

      • FormattingParseNode

        public FormattingParseNode()
    • Method Detail

      • computeLineNumberForNode

        public void computeLineNumberForNode​(LineFormatContext ctx,
                                             IParseNode toFindPN)
        Description copied from interface: IParseNode
        Internal method used to walk the parse tree to find the line number for a given parse node (which must be in the tree).
      • refersToSemanticValue

        public boolean refersToSemanticValue​(java.lang.Object obj)
      • updateSemanticValue

        public void updateSemanticValue​(java.util.IdentityHashMap<java.lang.Object,​java.lang.Object> oldNewMap)
      • getSemanticValue

        public java.lang.Object getSemanticValue()
      • setSemanticValue

        public void setSemanticValue​(java.lang.Object obj,
                                     boolean clearOld,
                                     boolean restore)
      • findStartDiff

        public void findStartDiff​(DiffContext ctx,
                                  boolean atEnd,
                                  java.lang.Object parSemVal,
                                  ParentParseNode parParseNode,
                                  int childIx)
        Description copied from interface: IParseNode
        Finds the first parse node whose text does not match the DiffContext
      • findEndDiff

        public void findEndDiff​(DiffContext ctx,
                                java.lang.Object parSemVal,
                                ParentParseNode parParseNode,
                                int childIx)
      • isGeneratedTree

        public boolean isGeneratedTree()
        Description copied from interface: IParseNode
        Returns true if any nodes in this tree have been through the 'generate' process. These nodes might have formatting parse nodes that need to be replaced for some operations
      • addParseErrors

        public void addParseErrors​(java.util.List<ParseError> res,
                                   int max)
        Description copied from interface: IParseNode
        For incremental parses, return the list of errors detected and continued in the parse-stream (useful for syntax highlighting)