com.google.protobuf.Descriptors.FieldDescriptor#getContainingType ( )源码实例Demo

下面列出了com.google.protobuf.Descriptors.FieldDescriptor#getContainingType ( ) 实例代码,或者点击链接到github查看源代码,也可以在右侧发表评论。

源代码1 项目: play-store-api   文件: DynamicMessage.java
/** Verifies that the field is a field of this message. */
private void verifyContainingType(FieldDescriptor field) {
  if (field.getContainingType() != type) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  }
}
 
源代码2 项目: play-store-api   文件: DynamicMessage.java
/** Verifies that the field is a field of this message. */
private void verifyContainingType(FieldDescriptor field) {
  if (field.getContainingType() != type) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  }
}
 
源代码3 项目: android-chromium   文件: GeneratedMessage.java
/** Get the FieldAccessor for a particular field. */
private FieldAccessor getField(final FieldDescriptor field) {
  if (field.getContainingType() != descriptor) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  } else if (field.isExtension()) {
    // If this type had extensions, it would subclass ExtendableMessage,
    // which overrides the reflection interface to handle extensions.
    throw new IllegalArgumentException(
      "This type does not have extensions.");
  }
  return fields[field.getIndex()];
}
 
源代码4 项目: play-store-api   文件: GeneratedMessage.java
/** Get the FieldAccessor for a particular field. */
private FieldAccessor getField(final FieldDescriptor field) {
  if (field.getContainingType() != descriptor) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  } else if (field.isExtension()) {
    // If this type had extensions, it would subclass ExtendableMessage,
    // which overrides the reflection interface to handle extensions.
    throw new IllegalArgumentException(
      "This type does not have extensions.");
  }
  return fields[field.getIndex()];
}
 
源代码5 项目: play-store-api   文件: MapEntry.java
private void checkFieldDescriptor(FieldDescriptor field) {
  if (field.getContainingType() != metadata.descriptor) {
    throw new RuntimeException(
        "Wrong FieldDescriptor \"" + field.getFullName()
        + "\" used in message \"" + metadata.descriptor.getFullName());
  }
}
 
源代码6 项目: android-chromium   文件: DynamicMessage.java
/** Verifies that the field is a field of this message. */
private void verifyContainingType(FieldDescriptor field) {
  if (field.getContainingType() != type) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  }
}
 
源代码7 项目: travelguide   文件: DynamicMessage.java
/** Verifies that the field is a field of this message. */
private void verifyContainingType(FieldDescriptor field) {
  if (field.getContainingType() != type) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  }
}
 
源代码8 项目: travelguide   文件: DynamicMessage.java
/** Verifies that the field is a field of this message. */
private void verifyContainingType(FieldDescriptor field) {
  if (field.getContainingType() != type) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  }
}
 
源代码9 项目: travelguide   文件: GeneratedMessage.java
/** Get the FieldAccessor for a particular field. */
private FieldAccessor getField(final FieldDescriptor field) {
  if (field.getContainingType() != descriptor) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  } else if (field.isExtension()) {
    // If this type had extensions, it would subclass ExtendableMessage,
    // which overrides the reflection interface to handle extensions.
    throw new IllegalArgumentException(
      "This type does not have extensions.");
  }
  return fields[field.getIndex()];
}
 
源代码10 项目: 365browser   文件: DynamicMessage.java
/** Verifies that the field is a field of this message. */
private void verifyContainingType(FieldDescriptor field) {
  if (field.getContainingType() != type) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  }
}
 
源代码11 项目: 365browser   文件: DynamicMessage.java
/** Verifies that the field is a field of this message. */
private void verifyContainingType(FieldDescriptor field) {
  if (field.getContainingType() != type) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  }
}
 
源代码12 项目: android-chromium   文件: GeneratedMessage.java
/** Get the FieldAccessor for a particular field. */
private FieldAccessor getField(final FieldDescriptor field) {
  if (field.getContainingType() != descriptor) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  } else if (field.isExtension()) {
    // If this type had extensions, it would subclass ExtendableMessage,
    // which overrides the reflection interface to handle extensions.
    throw new IllegalArgumentException(
      "This type does not have extensions.");
  }
  return fields[field.getIndex()];
}
 
源代码13 项目: 365browser   文件: GeneratedMessage.java
/** Get the FieldAccessor for a particular field. */
private FieldAccessor getField(final FieldDescriptor field) {
  if (field.getContainingType() != descriptor) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  } else if (field.isExtension()) {
    // If this type had extensions, it would subclass ExtendableMessage,
    // which overrides the reflection interface to handle extensions.
    throw new IllegalArgumentException(
      "This type does not have extensions.");
  }
  return fields[field.getIndex()];
}
 
源代码14 项目: android-chromium   文件: DynamicMessage.java
/** Verifies that the field is a field of this message. */
private void verifyContainingType(FieldDescriptor field) {
  if (field.getContainingType() != type) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  }
}
 
源代码15 项目: curiostack   文件: FieldScopeLogic.java
@Override
boolean matchesFieldDescriptor(Descriptor descriptor, FieldDescriptor fieldDescriptor) {
  return fieldDescriptor.getContainingType() == descriptor
      && fieldNumbers.contains(fieldDescriptor.getNumber());
}
 
源代码16 项目: play-store-api   文件: GeneratedMessage.java
private void verifyContainingType(final FieldDescriptor field) {
  if (field.getContainingType() != getDescriptorForType()) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  }
}
 
源代码17 项目: travelguide   文件: GeneratedMessage.java
private void verifyContainingType(final FieldDescriptor field) {
  if (field.getContainingType() != getDescriptorForType()) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  }
}
 
源代码18 项目: travelguide   文件: GeneratedMessage.java
private void verifyContainingType(final FieldDescriptor field) {
  if (field.getContainingType() != getDescriptorForType()) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  }
}
 
源代码19 项目: 365browser   文件: GeneratedMessage.java
private void verifyContainingType(final FieldDescriptor field) {
  if (field.getContainingType() != getDescriptorForType()) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  }
}
 
源代码20 项目: android-chromium   文件: GeneratedMessage.java
private void verifyContainingType(final FieldDescriptor field) {
  if (field.getContainingType() != getDescriptorForType()) {
    throw new IllegalArgumentException(
      "FieldDescriptor does not match message type.");
  }
}