public override void debugVisitOnstageChildren(ElementVisitor visitor) { foreach (var child in LinqUtils <Element> .WhereList(children, (_shouldPaint))) { visitor(child); } }
public override void debugVisitOnstageChildren(ElementVisitor visitor) { if (!widget.offstage) { base.debugVisitOnstageChildren(visitor); } }
public override void debugVisitOnstageChildren(ElementVisitor visitor) { LinqUtils <Element> .WhereList(children, (e => { RenderSliver renderSliver = (RenderSliver)e.renderObject; return(renderSliver.geometry.visible); })).ForEach(e => visitor(e)); }
public override void visitChildren(ElementVisitor visitor) { if (this._child != null) { visitor(this._child); } }
public override void debugVisitOnstageChildren(ElementVisitor visitor) { this.children.Where(e => { RenderSliver renderSliver = (RenderSliver)e.renderObject; return(renderSliver.geometry.visible); }).ToList().ForEach(e => visitor(e)); }
public override void debugVisitOnstageChildren(ElementVisitor visitor) { if (this._onstage != null) { visitor(this._onstage); } }
public override void visitChildren(ElementVisitor visitor) { foreach (var element in this.slotToChild.Values) { visitor(element); } }
public override void visitChildren(ElementVisitor visitor) { foreach (var item in this._childElements) { visitor(item.Value); } }
public override void visitChildren(ElementVisitor visitor) { D.assert(!_childElements.Values.Any(child => child == null)); foreach (var e in _childElements.Values) { visitor(e); } }
public override void debugVisitOnstageChildren(ElementVisitor visitor) { D.assert(children.Count() >= widget.skipCount); foreach (var item in children.Skip(widget.skipCount)) { visitor(item); } }
public override void visitChildren(ElementVisitor visitor) { if (_prototype != null) { visitor(_prototype); } base.visitChildren(visitor); }
public FunctionVisitor(Type annotationType, Types types, Elements elements, TypeMirrorUtils typeMirrorUtils, System.Func <T, Optional <string> > customNameExtractor, bool ignoresWarnings) { annotationType = typeof(T); this._customNameExtractor = customNameExtractor; this._annotationType = annotationType; this._classVisitor = new ExtensionClassVisitor(types, elements, ignoresWarnings); this._parameterVisitor = new ParameterVisitor(new ParameterTypeVisitor(types, typeMirrorUtils)); this._elements = elements; this._allowedTypesValidator = new AllowedTypesValidator(typeMirrorUtils, types); }
public ProcedureVisitor(Types typeUtils, Elements elementUtils, bool ignoresWarnings) { TypeMirrorUtils typeMirrors = new TypeMirrorUtils(typeUtils, elementUtils); this._typeUtils = typeUtils; this._elementUtils = elementUtils; this._classVisitor = new ExtensionClassVisitor(typeUtils, elementUtils, ignoresWarnings); this._recordVisitor = new RecordTypeVisitor(typeUtils, typeMirrors); this._parameterVisitor = new ParameterVisitor(new ParameterTypeVisitor(typeUtils, typeMirrors)); this._performsWriteVisitor = new PerformsWriteMethodVisitor(); }
public static void each <Element>(this IEnumerable <Element> items, ElementVisitor <Element> visitor) { foreach (var element in items) { var result = visitor(element); if (!result) { return; } } }
public override void Init(ProcessingEnvironment processingEnv) { lock (this) { base.Init(processingEnv); _messagePrinter = new MessagePrinter(processingEnv.Messager); _duplicationValidator = new DuplicatedExtensionValidator <ICollection <Element>, Stream <CompilationMessage> >(processingEnv.ElementUtils, _supportedAnnotationType, _customNameFunction); _visitor = _visitorSupplier.apply(processingEnv); } }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Before public void prepare() public virtual void Prepare() { Types types = CompilationRule.Types; Elements elements = CompilationRule.Elements; _elementTestUtils = new ElementTestUtils(CompilationRule); //JAVA TO C# CONVERTER WARNING: The original Java variable was marked 'final': //ORIGINAL LINE: final org.neo4j.tooling.procedure.compilerutils.TypeMirrorUtils typeMirrorUtils = new org.neo4j.tooling.procedure.compilerutils.TypeMirrorUtils(types, elements); TypeMirrorUtils typeMirrorUtils = new TypeMirrorUtils(types, elements); _visitor = new UserFunctionVisitor(new FunctionVisitor <UserFunction>(typeof(UserFunction), types, elements, typeMirrorUtils, function => CustomNameExtractor.getName(function.name, function.value), false)); }
public override void visitChildren(ElementVisitor visitor) { if (_contentElement != null) { visitor(_contentElement); } if (_actionsElement != null) { visitor(_actionsElement); } }
public override void visitChildren(ElementVisitor visitor) { foreach (_TableElementRow row in _children) { foreach (Element child in row.children) { if (!_forgottenChildren.Contains(child)) { visitor(child); } } } }
/** * Walks child nodes of the given node. * @param element * @param visitors Map of tag names to visitors for that tag. */ private static void walk(XmlElement element, Dictionary <String, ElementVisitor> visitors) { XmlNodeList children = element.ChildNodes; for (int i = 0, j = children.Count; i < j; ++i) { XmlNode child = children[i]; ElementVisitor visitor = visitors[child.Name]; if (visitor != null) { visitor.visit((XmlElement)child); } } }
public override void visitChildren(ElementVisitor visitor) { if (this._onstage != null) { visitor(this._onstage); } foreach (var child in this._offstage) { if (!this._forgottenOffstageChildren.Contains(child)) { visitor(child); } } }
public override Document VisitParse([NotNull] ParseContext context) { var elementVisitor = new ElementVisitor().Inherit(this); var raw = new List <IElement>(); foreach (var element in context.element()) { var item = elementVisitor.VisitElement(element); raw.Add(item); } var result = new Document(); result.Eat(raw, this); return(result); }
public override Section VisitSection(SectionContext context) { var titleVisitor = new TextAreasVisitor().Inherit(this); var title = titleVisitor.VisitTitle(context.title()); var separator = context.SectionSeparator()[0].GetText(); var level = SectionTracker.Track(separator[0]); var list = new List <IElement>(); var elementVisitor = new ElementVisitor().Inherit(this); var element = context.sectionElement(); if (element != null) { foreach (var item in element) { list.Add(elementVisitor.VisitSectionElement(item)); } } return(new Section(level, title, list, context.overline != null)); }
public override void debugVisitOnstageChildren(ElementVisitor visitor) { this._childElements.Values.Where(child => { SliverMultiBoxAdaptorParentData parentData = (SliverMultiBoxAdaptorParentData)child.renderObject.parentData; double itemExtent = 0; switch (this.renderObject.constraints.axis) { case Axis.horizontal: itemExtent = child.renderObject.paintBounds.width; break; case Axis.vertical: itemExtent = child.renderObject.paintBounds.height; break; } return(parentData.layoutOffset < this.renderObject.constraints.scrollOffset + this.renderObject.constraints.remainingPaintExtent && parentData.layoutOffset + itemExtent > this.renderObject.constraints.scrollOffset); }).ToList().ForEach(e => visitor(e)); }
public override void debugVisitOnstageChildren(ElementVisitor visitor) { LinqUtils <Element> .WhereList(_childElements.Values, (child => { SliverMultiBoxAdaptorParentData parentData = (SliverMultiBoxAdaptorParentData)child.renderObject.parentData; float itemExtent = 0; switch (renderObject.constraints.axis) { case Axis.horizontal: itemExtent = child.renderObject.paintBounds.width; break; case Axis.vertical: itemExtent = child.renderObject.paintBounds.height; break; } return(parentData.layoutOffset != null && parentData.layoutOffset < renderObject.constraints.scrollOffset + renderObject.constraints.remainingPaintExtent && parentData.layoutOffset + itemExtent > renderObject.constraints.scrollOffset); })).ForEach(e => visitor(e)); }
public override IElement VisitElement([NotNull] ElementContext context) { var sectionContext = context.section(); if (sectionContext != null) { var sectionVisitor = new SectionVisitor().Inherit(this); var section = sectionVisitor.VisitSection(sectionContext); return(section); } var sectionElementContext = context.sectionElement(); if (sectionElementContext != null) { var elementVisitor = new ElementVisitor().Inherit(this); var element = elementVisitor.VisitSectionElement(context.sectionElement()); return(element); } //TODO: throw a better exception. throw new InvalidOperationException(); }
public override void AcceptVisitor(ElementVisitor visitor) { visitor.Visit(this); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Before public void prepare() public virtual void Prepare() { _elementTestUtils = new ElementTestUtils(CompilationRule); _fieldVisitor = new FieldVisitor(CompilationRule.Types, CompilationRule.Elements, true); }
public UserAggregationFunctionVisitor(FunctionVisitor <UserAggregationFunction> baseFunctionVisitor, Types types) { this._functionVisitor = baseFunctionVisitor; this._types = types; this._typeVisitor = new QualifiedTypeVisitor(); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Before public void prepare() public virtual void Prepare() { _elementTestUtils = new ElementTestUtils(CompilationRule); _contextFieldVisitor = new ContextFieldVisitor(CompilationRule.Types, CompilationRule.Elements, false); }
public FieldVisitor(Types types, Elements elements, bool ignoresWarnings) { _contextFieldVisitor = new ContextFieldVisitor(types, elements, ignoresWarnings); }