~ubuntu-branches/debian/stretch/protobuf/stretch

« back to all changes in this revision

Viewing changes to java/src/main/java/com/google/protobuf/MessageOrBuilder.java

  • Committer: Package Import Robot
  • Author(s): Robert S. Edmonds
  • Date: 2014-09-11 22:50:10 UTC
  • mfrom: (10.1.9 experimental)
  • Revision ID: package-import@ubuntu.com-20140911225010-wt4yo9dpc1fzuq5g
Tags: 2.6.0-3
Upload to unstable.

Show diffs side-by-side

added added

removed removed

Lines of Context:
76
76
   * Returns a collection of all the fields in this message which are set
77
77
   * and their corresponding values.  A singular ("required" or "optional")
78
78
   * field is set iff hasField() returns true for that field.  A "repeated"
79
 
   * field is set iff getRepeatedFieldSize() is greater than zero.  The
 
79
   * field is set iff getRepeatedFieldCount() is greater than zero.  The
80
80
   * values are exactly what would be returned by calling
81
81
   * {@link #getField(Descriptors.FieldDescriptor)} for each field.  The map
82
82
   * is guaranteed to be a sorted map, so iterating over it will return fields
89
89
  Map<Descriptors.FieldDescriptor, Object> getAllFields();
90
90
 
91
91
  /**
 
92
   * Returns true if the given oneof is set.
 
93
   * @throws IllegalArgumentException if
 
94
   *           {@code oneof.getContainingType() != getDescriptorForType()}.
 
95
   */
 
96
  boolean hasOneof(Descriptors.OneofDescriptor oneof);
 
97
 
 
98
  /**
 
99
   * Obtains the FieldDescriptor if the given oneof is set. Returns null
 
100
   * if no field is set.
 
101
   */
 
102
  Descriptors.FieldDescriptor getOneofFieldDescriptor(
 
103
      Descriptors.OneofDescriptor oneof);
 
104
 
 
105
  /**
92
106
   * Returns true if the given field is set.  This is exactly equivalent to
93
107
   * calling the generated "has" accessor method corresponding to the field.
94
108
   * @throws IllegalArgumentException The field is a repeated field, or