Emits {@code modifiers} in the standard order. Modifiers in {@code implicitModifiers} will not
be emitted.
8184
public void emitModifiers(Set<Modifier> modifiers, Set<Modifier> implicitModifiers)
      throws IOException {
    if (modifiers.isEmpty()) return;
    for (Modifier modifier : EnumSet.copyOf(modifiers)) {
      if (implicitModifiers.contains(modifier)) continue;
      emitAndIndent(modifier.name().toLowerCase(Locale.US));
      emitAndIndent(" ");
    }
  }
76603
static void modifiersToString(final int modifiers, final StringBuilder buf) {
        if ((modifiers & Modifier.FINAL) != 0) {
            buf.append("final ");
        }
        if ((modifiers & 0x1000) != 0) {
            buf.append("synthetic ");
        }
        if ((modifiers & 0x8000) != 0) {
            buf.append("mandated ");
        }
    }
486826
public static int compareModifierVisibility(Element a, Element b) {


    // a better
    if (a.getModifiers().contains(Modifier.PUBLIC) && !b.getModifiers().contains(Modifier.PUBLIC)) {
      return -1;
    }

    if (isDefaultModifier(a.getModifiers()) && !isDefaultModifier(b.getModifiers())) {
      return -1;
    }

    if (a.getModifiers().contains(Modifier.PROTECTED) && !b.getModifiers().contains(Modifier.PROTECTED)) {
      return -1;
    }


    // b better
    if (b.getModifiers().contains(Modifier.PUBLIC) && !a.getModifiers().contains(Modifier.PUBLIC)) {
      return 1;
    }

    if (isDefaultModifier(b.getModifiers()) && !isDefaultModifier(a.getModifiers())) {
      return 1;
    }

    if (b.getModifiers().contains(Modifier.PROTECTED) && !a.getModifiers().contains(Modifier.PROTECTED)) {
      return 1;
    }

    // Same
    return 0;
  }
655872
@Requires("modifier != null")
  @Ensures("getModifiers().contains(modifier)")
  public void addModifier(ElementModifier modifier) {
    switch (modifier) {
      case PRIVATE:
      case PACKAGE_PRIVATE:
      case PROTECTED:
      case PUBLIC:
        modifiers.remove(ElementModifier.PRIVATE);
        modifiers.remove(ElementModifier.PACKAGE_PRIVATE);
        modifiers.remove(ElementModifier.PROTECTED);
        modifiers.remove(ElementModifier.PUBLIC);
    }
    modifiers.add(modifier);
  }
930440
public static String printArgModifiers(List<ArgModifier> modifiers) {
        final StringBuilder builder = new StringBuilder();
        if (modifiers.contains(ArgModifier._Final())) {
            builder.append(print(ArgModifier._Final()));
            builder.append(" ");
        }
        if (modifiers.contains(ArgModifier._Transient())) {
            builder.append(print(ArgModifier._Transient()));
            builder.append(" ");
        }
        if (modifiers.contains(ArgModifier._Volatile())) {
            builder.append(print(ArgModifier._Volatile()));
            builder.append(" ");
        }
        return builder.toString();
    }
690913
public static void checkMethodModifiers(final int modifiers) {

        // Base check
        checkModifiers(METHOD, modifiers);

        // Check overlapping modifiers
        if (Modifier.isPrivate(modifiers)) {
            if (Modifier.isProtected(modifiers) || Modifier.isPublic(modifiers)) {
                throw new IllegalArgumentException(METHOD_ACCESS_MODIFIER_ERROR + " ["
                        + Modifier.toString(modifiers) + "]");
            }
        }
        if (Modifier.isProtected(modifiers)) {
            if (Modifier.isPrivate(modifiers) || Modifier.isPublic(modifiers)) {
                throw new IllegalArgumentException(METHOD_ACCESS_MODIFIER_ERROR + " ["
                        + Modifier.toString(modifiers) + "]");
            }
        }
        if (Modifier.isPublic(modifiers)) {
            if (Modifier.isPrivate(modifiers) || Modifier.isProtected(modifiers)) {
                throw new IllegalArgumentException(METHOD_ACCESS_MODIFIER_ERROR + " ["
                        + Modifier.toString(modifiers) + "]");
            }
        }

        // Check illegal abstract modifiers
        if (Modifier.isAbstract(modifiers)) {
            if (Modifier.isPrivate(modifiers) || Modifier.isStatic(modifiers)
                    || Modifier.isFinal(modifiers) || Modifier.isNative(modifiers)
                    || Modifier.isStrict(modifiers) || Modifier.isSynchronized(modifiers)) {
                throw new IllegalArgumentException(METHOD_ILLEGAL_ABSTRACT_MODIFIERS_ERROR + " ["
                        + Modifier.toString(modifiers) + "]");
            }
        }

        // Check native and strictfp
        if (Modifier.isNative(modifiers) && Modifier.isStrict(modifiers)) {
            throw new IllegalArgumentException(METHOD_NATIVE_STRICTFP_ERROR + " ["
                    + Modifier.toString(modifiers) + "]");
        }

    }
74086
public static int getModifiersFrom( IAttributedFeatureInfo afi )
  {
    int iModifiers = 0;
    iModifiers = Modifier.setBit( iModifiers, afi.isPublic(), PUBLIC );
    iModifiers = Modifier.setBit( iModifiers, afi.isPrivate(), PRIVATE );
    iModifiers = Modifier.setBit( iModifiers, afi.isProtected(), PROTECTED );
    iModifiers = Modifier.setBit( iModifiers, afi.isInternal(), INTERNAL );
    iModifiers = Modifier.setBit( iModifiers, afi.isStatic(), STATIC );
    iModifiers = Modifier.setBit( iModifiers, afi.isFinal(), FINAL );
    iModifiers = Modifier.setBit( iModifiers, afi.isReified(), REIFIED );
    return iModifiers;
  }
415044
private static int modifiersToInt(ModifierType... modifierTypes) {
		int modifier = modifierTypes[0].getValue();
		for(int i = 1; i < modifierTypes.length; i++) {
			modifier &= modifierTypes[i].getValue();
		}
		return modifier;
	}
691753
function (modifierName, out) {
                var modifier = __modifiers[modifierName];
                if (modifier && modifier.init) {
                    modifier.init(out);
                }
            }
731931
public void addModifier(Modifier modifier) {
		if (modifier != null) {
			final String ruleName = modifier.getType();
			if (!Strings.isEmpty(ruleName)) {
				List<String> modifiers = this.modifiers.get(ruleName);
				if (modifiers == null) {
					modifiers = new ArrayList<>();
					this.modifiers.put(ruleName, modifiers);
				}
				modifiers.addAll(modifier.getModifiers());
			}
		}
	}
563688
public function compileModifiers()
    {
        if (count($this->modifiers) === 0) {
            return;
        }

        $processed_modifiers = [];

        foreach ($this->modifiers as $k => $v) {
            $processed_modifiers[] = urlencode($k).'('.urlencode($v).')';
        }

        $this->compiledValues[] = '.'.implode('.', $processed_modifiers);
    }
74129
public static Optional<SuggestedFix> removeModifiers(
      Tree tree, VisitorState state, Modifier... modifiers) {
    Set<Modifier> toRemove = ImmutableSet.copyOf(modifiers);
    ModifiersTree originalModifiers = getModifiers(tree);
    if (originalModifiers == null) {
      return Optional.empty();
    }
    return removeModifiers(originalModifiers, state, toRemove);
  }
1275779
public void addModifier(String modifier) {
		if (!Strings.isEmpty(modifier)) {
			this.sarlAgent.getModifiers().add(modifier);
		}
	}
161570
def warn(self, collection):
        """"""
        super(CodeElement, self).warn(collection)
        if not "implicit none" in self.modifiers:
            collection.append("WARNING: implicit none not set in {}".format(self.name))
1201442
public String modifiers() {
        int modifiers = getModifiers();
        if (isAnnotationTypeElement() ||
                (isMethod() && containingClass().isInterface())) {
            // Remove the implicit abstract modifier.
            return Modifier.toString(modifiers & ~Modifier.ABSTRACT);
        } else {
            return Modifier.toString(modifiers);
        }
    }
651727
function updateModifiers() {
  if (this.state.isDestroyed) {
    return;
  }
  // Deep merge modifiers options
  let options = this.defaultOptions;
  this.options.modifiers = {};
  const _this = this;
  Object.keys(_extends({}, Popper.Defaults.modifiers, options.modifiers)).forEach(function (name) {
    _this.options.modifiers[name] = _extends({}, Popper.Defaults.modifiers[name] || {}, options.modifiers ? options.modifiers[name] : {});
  });

  // Refactoring modifiers' list (Object => Array)
  this.modifiers = Object.keys(this.options.modifiers).map(function (name) {
    return _extends({
      name: name
    }, _this.options.modifiers[name]);
  })
  // sort the modifiers by order
    .sort(function (a, b) {
      return a.order - b.order;
    });

  // modifiers have the ability to execute arbitrary code when Popper.js get inited
  // such code is executed in the same order of its modifier
  // they could add new properties to their options configuration
  // BE AWARE: don't add options to `options.modifiers.name` but to `modifierOptions`!
  this.modifiers.forEach(function (modifierOptions) {
    if (modifierOptions.enabled && isFunction(modifierOptions.onLoad)) {
      modifierOptions.onLoad(_this.reference, _this.popper, _this.options, modifierOptions, _this.state);
    }
  });
}
207752
int getModifiers() {
        int modifiers = KeyEvent.MODIFIER_NONE;
        for (int i = 0; i < buttonsPressed.size(); i++) {
            switch(buttonsPressed.get(i)) {
                case MouseEvent.BUTTON_LEFT:
                    modifiers |= KeyEvent.MODIFIER_BUTTON_PRIMARY;
                    break;
                case MouseEvent.BUTTON_OTHER:
                    modifiers |= KeyEvent.MODIFIER_BUTTON_MIDDLE;
                    break;
                case MouseEvent.BUTTON_RIGHT:
                    modifiers |= KeyEvent.MODIFIER_BUTTON_SECONDARY;
                    break;
            }
        }
        return modifiers;
    }