private static void checkRange( ContentElement ce ){ List<SrcSpan> eil = new ArrayList<SrcSpan>(); for( Span s: ce.getFormatSpans( FormatType.BOLD ) ) eil.add( s.getSrcSpan() ); for( Span s: ce.getFormatSpans( FormatType.ITALIC ) ) eil.add( s.getSrcSpan() ); for( Span s: ce.getFormatSpans( FormatType.MATH ) ) eil.add( s.getSrcSpan() ); for( Span s: ce.getFormatSpans( FormatType.TAG ) ) eil.add( s.getSrcSpan() ); for( Span s: ce.getFormatSpans( FormatType.NOWIKI ) ) eil.add( s.getSrcSpan() ); for( Link l: ce.getLinks()) eil.add( l.getSrcSpan() ); for( Template t: ce.getTemplates() ) eil.add( t.getSrcSpan() ); ce.setSrcSpan( getEvalInfo( ce.getSrcSpan(), eil) ); }
public Span clone(){ Span result = new Span( start, end ); result.setSrcSpan( this.getSrcSpan() ); return result; } }