Examples of WhenToApply


Examples of com.puppetlabs.geppetto.pp.dsl.formatting.IBreakAndAlignAdvice.WhenToApply

  @Override
  protected IBreakAndAlignAdvice dataForResource(IResource resource) {
    final int clusterSize = formatterPreferences.getClusterSize(resource);
    final WhenToApplyForDefinition definitionParameters = formatterPreferences.getDefinitionParametersAdvice(resource);
    final WhenToApply hashes = formatterPreferences.getHashesAdvice(resource);
    final WhenToApply lists = formatterPreferences.getListsAdvice(resource);
    final boolean compact = formatterPreferences.isCompactCases(resource);
    final boolean alignCases = formatterPreferences.isAlignCases(resource);
    final boolean compactResource = formatterPreferences.isCompactResources(resource);
    final boolean alignAssignments = formatterPreferences.isAlignAssignments(resource);
View Full Code Here

Examples of com.puppetlabs.geppetto.pp.dsl.formatting.IBreakAndAlignAdvice.WhenToApply

  Provider<IBreakAndAlignAdvice> breakAlignAdviceProvider;

  protected boolean format(IDomNode node, ITextFlow flow, ILayoutContext context) {

    final IBreakAndAlignAdvice advisor = getAlignAdvice();
    final WhenToApply advice = advisor.listsAdvice();
    final int clusterWidth = advisor.clusterSize();

    boolean breakAndAlign = false;
    // Do not break and align unless there is more than one element in the list/hash
    if(hasMoreThanOneElement(node.getSemanticObject()))
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.