Examples of Enum


Examples of com.google.eclipse.protobuf.protobuf.Enum

      field = (MessageField) model.eContainer();
    }
    if (field == null || !messageFields.isOptional(field)) {
      return;
    }
    Enum enumType = messageFields.enumTypeOf(field);
    if (enumType != null) {
      proposeAndAccept(enumType, context, acceptor);
    }
  }
View Full Code Here

Examples of com.google.eclipse.protobuf.protobuf.Enum

      ContentAssistContext context, ICompletionProposalAcceptor acceptor) {
    if (model instanceof NativeFieldOption) {
      NativeFieldOption option = (NativeFieldOption) model;
      ProtoDescriptor descriptor = descriptorProvider.primaryDescriptor();
      MessageField field = (MessageField) options.rootSourceOf(option);
      Enum enumType = descriptor.enumTypeOf(field);
      if (enumType != null) {
        proposeAndAccept(enumType, context, acceptor);
        return;
      }
      proposePrimitiveValues(field, context, acceptor);
View Full Code Here

Examples of com.google.eclipse.protobuf.protobuf.Enum

  private void proposeFieldValue(MessageField field, ContentAssistContext context,
      ICompletionProposalAcceptor acceptor) {
    if (field == null || proposePrimitiveValues(field, context, acceptor)) {
      return;
    }
    Enum enumType = messageFields.enumTypeOf(field);
    if (enumType != null) {
      proposeAndAccept(enumType, context, acceptor);
    }
  }
View Full Code Here

Examples of com.google.eclipse.protobuf.protobuf.Enum

  }

  @SuppressWarnings("unused")
  public IScope scope_LiteralLink_target(LiteralLink link, EReference r) {
    EObject container = link.eContainer();
    Enum anEnum = null;
    if (container instanceof DefaultValueFieldOption) {
      container = container.eContainer();
    }
    if (container instanceof AbstractOption) {
      AbstractOption option = (AbstractOption) container;
View Full Code Here

Examples of com.google.eclipse.protobuf.protobuf.Enum

  // syntax = "proto2";
  //
  // enum PhoneType {}
  @Test public void should_return_image_for_enum() {
    Enum anEnum = xtext.find("PhoneType", Enum.class);
    String image = images.imageFor(anEnum);
    assertThat(image, equalTo("enum.gif"));
    assertThat(image, existsInProject());
  }
View Full Code Here

Examples of com.google.eclipse.protobuf.protobuf.Enum

    }
    if (messageFields.isBytes(field) || messageFields.isString(field)) {
      validateString(option);
      return;
    }
    Enum anEnum = messageFields.enumTypeOf(field);
    if (anEnum != null) {
      validateEnumLiteral(option, anEnum);
    }
  }
View Full Code Here

Examples of com.sun.star.uno.Enum

            newValue = null ;

            for (int i = 0; i < flds.length; i++) {
                if (Enum.class.equals(flds[i].getType().getSuperclass())) {

                    Enum value = (Enum) flds[i].get(null) ;
                    if (newValue == null && !value.equals(oldValue)) {
                        newValue = value ;
                        break ;
                    }
                }
            }
View Full Code Here

Examples of edu.indiana.dde.mylead.agent.xmlbeans.StatusEnumType.Enum

      OperationResponseDocument responce = stub.addUsers(reqDoc);
      if (null == responce || null == responce.getOperationResponse()) {
        throw new MyLeadException("Invalid responce");
      }
      OperationResponseType outputType = responce.getOperationResponse();
      Enum status = outputType.getStatus();
      String queryResult = null;
      if (status.equals(StatusEnumType.SUCCESS)) {
        if (outputType.isSetMessage()) {
          queryResult = outputType.getMessage();
        }
      } else {
        if (outputType.isSetMessage()) {
View Full Code Here

Examples of gnu.x11.Enum

     */
    Atom[] getWmState(Display display, Window win) {
  ArrayList<Atom> res = new ArrayList<Atom>();
  Window.PropertyReply rep = win.property(false, netWmState, Atom.ATOM,
    0, 5);
  Enum enm = rep.items();
  while (enm.more()) {
      Atom atom = (Atom) Atom.intern(display, enm.next_integer());
      res.add(atom);
      logger.fine("WM State: " + win + " " + atom);
  }
  if (res.size() > 0) {
      return res.toArray(new Atom[res.size()]);
View Full Code Here

Examples of org.apache.commons.lang.enums.Enum

     */
    public void setAsText(String text) throws IllegalArgumentException {
        if (this.allowEmpty && !StringUtils.hasText(text)) {
            setValue(null);
        } else {
            Enum eNum = EnumUtils.getEnum(enumClass, text);
            if (eNum != null) {
                setValue(eNum);
            } else {
                throw new IllegalArgumentException("Invalid enum name: " + text);
            }
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.