diff --git a/DataExtractionOSM/src/gnu/trove/list/TByteList.java b/DataExtractionOSM/src/gnu/trove/list/TByteList.java
new file mode 100644
index 0000000000..3959990c27
--- /dev/null
+++ b/DataExtractionOSM/src/gnu/trove/list/TByteList.java
@@ -0,0 +1,518 @@
+///////////////////////////////////////////////////////////////////////////////
+// Copyright (c) 2009, Rob Eden All Rights Reserved.
+// Copyright (c) 2009, Jeff Randall All Rights Reserved.
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this program; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+///////////////////////////////////////////////////////////////////////////////
+
+package gnu.trove.list;
+
+//////////////////////////////////////////////////
+// THIS IS A GENERATED CLASS. DO NOT HAND EDIT! //
+//////////////////////////////////////////////////
+
+
+import gnu.trove.function.*;
+import gnu.trove.procedure.*;
+import gnu.trove.TByteCollection;
+
+import java.io.Serializable;
+import java.util.Random;
+
+
+
+/**
+ * Interface for Trove list implementations.
+ */
+public interface TByteList extends TByteCollection, Serializable {
+
+ /**
+ * Returns the value that is used to represent null. The default
+ * value is generally zero, but can be changed during construction
+ * of the collection.
+ *
+ * @return the value that represents null
+ */
+ @Override
+ public byte getNoEntryValue();
+
+
+ /**
+ * Returns the number of values in the list.
+ *
+ * @return the number of values in the list.
+ */
+ @Override
+ public int size();
+
+
+ /**
+ * Tests whether this list contains any values.
+ *
+ * @return true if the list is empty.
+ */
+ @Override
+ public boolean isEmpty();
+
+
+ /**
+ * Adds val to the end of the list, growing as needed.
+ *
+ * @param val an byte
value
+ * @return true if the list was modified by the add operation
+ */
+ @Override
+ public boolean add(byte val);
+
+
+ /**
+ * Adds the values in the array vals to the end of the
+ * list, in order.
+ *
+ * @param vals an byte[]
value
+ */
+ public void add( byte[] vals );
+
+
+ /**
+ * Adds a subset of the values in the array vals to the
+ * end of the list, in order.
+ *
+ * @param vals an byte[]
value
+ * @param offset the offset at which to start copying
+ * @param length the number of values to copy.
+ */
+ public void add( byte[] vals, int offset, int length );
+
+
+ /**
+ * Inserts value into the list at offset. All
+ * values including and to the right of offset are shifted
+ * to the right.
+ *
+ * @param offset an int
value
+ * @param value an byte
value
+ */
+ public void insert( int offset, byte value );
+
+
+ /**
+ * Inserts the array of values into the list at
+ * offset. All values including and to the right of
+ * offset are shifted to the right.
+ *
+ * @param offset an int
value
+ * @param values an byte[]
value
+ */
+ public void insert( int offset, byte[] values );
+
+
+ /**
+ * Inserts a slice of the array of values into the list
+ * at offset. All values including and to the right of
+ * offset are shifted to the right.
+ *
+ * @param offset an int
value
+ * @param values an byte[]
value
+ * @param valOffset the offset in the values array at which to
+ * start copying.
+ * @param len the number of values to copy from the values array
+ */
+ public void insert( int offset, byte[] values, int valOffset, int len );
+
+
+ /**
+ * Returns the value at the specified offset.
+ *
+ * @param offset an int
value
+ * @return an byte
value
+ */
+ public byte get( int offset );
+
+
+ /**
+ * Sets the value at the specified offset.
+ *
+ * @param offset an int
value
+ * @param val an byte
value
+ *
+ * @return The value previously at the given index.
+ */
+ public byte set( int offset, byte val );
+
+
+ /**
+ * Replace the values in the list starting at offset with
+ * the contents of the values array.
+ *
+ * @param offset the first offset to replace
+ * @param values the source of the new values
+ */
+ public void set( int offset, byte[] values );
+
+
+ /**
+ * Replace the values in the list starting at offset with
+ * length values from the values array, starting
+ * at valOffset.
+ *
+ * @param offset the first offset to replace
+ * @param values the source of the new values
+ * @param valOffset the first value to copy from the values array
+ * @param length the number of values to copy
+ */
+ public void set( int offset, byte[] values, int valOffset, int length );
+
+
+ /**
+ * Sets the value at the specified offset and returns the
+ * previously stored value.
+ *
+ * @param offset an int
value
+ * @param val an byte
value
+ * @return the value previously stored at offset.
+ */
+ public byte replace( int offset, byte val );
+
+
+ /**
+ * Flushes the internal state of the list, resetting the capacity
+ * to the default.
+ */
+ @Override
+ public void clear();
+
+
+ /**
+ * Removes value from the list.
+ *
+ * @param value an byte
value
+ * @return true if the list was modified by the remove operation.
+ */
+ @Override
+ public boolean remove( byte value );
+
+
+ /**
+ * Removes value at a given offset from the list.
+ *
+ * @param offset an int
value that represents
+ * the offset to the element to be removed
+ * @return an byte that is the value removed.
+ */
+ public byte removeAt( int offset );
+
+
+ /**
+ * Removes length values from the list, starting at
+ * offset
+ *
+ * @param offset an int
value
+ * @param length an int
value
+ */
+ public void remove( int offset, int length );
+
+
+ /**
+ * Transform each value in the list using the specified function.
+ *
+ * @param function a TByteFunction
value
+ */
+ public void transformValues( TByteFunction function );
+
+
+ /**
+ * Reverse the order of the elements in the list.
+ */
+ public void reverse();
+
+
+ /**
+ * Reverse the order of the elements in the range of the list.
+ *
+ * @param from the inclusive index at which to start reversing
+ * @param to the exclusive index at which to stop reversing
+ */
+ public void reverse( int from, int to );
+
+
+ /**
+ * Shuffle the elements of the list using the specified random
+ * number generator.
+ *
+ * @param rand a Random
value
+ */
+ public void shuffle( Random rand );
+
+
+ /**
+ * Returns a sublist of this list.
+ *
+ * @param begin low endpoint (inclusive) of the subList.
+ * @param end high endpoint (exclusive) of the subList.
+ * @return sublist of this list from begin, inclusive to end, exclusive.
+ * @throws IndexOutOfBoundsException - endpoint out of range
+ * @throws IllegalArgumentException - endpoints out of order (end > begin)
+ */
+ public TByteList subList( int begin, int end );
+
+
+ /**
+ * Copies the contents of the list into a native array.
+ *
+ * @return an byte[]
value
+ */
+ @Override
+ public byte[] toArray();
+
+
+ /**
+ * Copies a slice of the list into a native array.
+ *
+ * @param offset the offset at which to start copying
+ * @param len the number of values to copy.
+ * @return an byte[]
value
+ */
+ public byte[] toArray( int offset, int len );
+
+
+ /**
+ * Copies a slice of the list into a native array.
+ *
+ *
If the list fits in the specified array with room to spare (i.e.,
+ * the array has more elements than the list), the element in the array
+ * immediately following the end of the list is set to
+ * {@link #getNoEntryValue()}.
+ * (This is useful in determining the length of the list only if
+ * the caller knows that the list does not contain any "null" elements.)
+ *
+ *
NOTE: Trove does not allocate a new array if the array passed in is
+ * not large enough to hold all of the data elements. It will instead fill
+ * the array passed in.
+ *
+ * @param dest the array to copy into.
+ * @return the array passed in.
+ */
+ @Override
+ public byte[] toArray( byte[] dest );
+
+
+ /**
+ * Copies a slice of the list into a native array.
+ *
+ * @param dest the array to copy into.
+ * @param offset the offset where the first value should be copied
+ * @param len the number of values to copy.
+ * @return the array passed in.
+ */
+ public byte[] toArray( byte[] dest, int offset, int len );
+
+
+ /**
+ * Copies a slice of the list into a native array.
+ *
+ * @param dest the array to copy into.
+ * @param source_pos the offset of the first value to copy
+ * @param dest_pos the offset where the first value should be copied
+ * @param len the number of values to copy.
+ * @return the array passed in.
+ */
+ public byte[] toArray( byte[] dest, int source_pos, int dest_pos, int len );
+
+
+ /**
+ * Applies the procedure to each value in the list in ascending
+ * (front to back) order.
+ *
+ * @param procedure a TByteProcedure
value
+ * @return true if the procedure did not terminate prematurely.
+ */
+ @Override
+ public boolean forEach( TByteProcedure procedure );
+
+
+ /**
+ * Applies the procedure to each value in the list in descending
+ * (back to front) order.
+ *
+ * @param procedure a TByteProcedure
value
+ * @return true if the procedure did not terminate prematurely.
+ */
+ public boolean forEachDescending( TByteProcedure procedure );
+
+
+ /**
+ * Sort the values in the list (ascending) using the Sun quicksort
+ * implementation.
+ *
+ * @see java.util.Arrays#sort
+ */
+ public void sort();
+
+
+ /**
+ * Sort a slice of the list (ascending) using the Sun quicksort
+ * implementation.
+ *
+ * @param fromIndex the index at which to start sorting (inclusive)
+ * @param toIndex the index at which to stop sorting (exclusive)
+ * @see java.util.Arrays#sort
+ */
+ public void sort( int fromIndex, int toIndex );
+
+
+ /**
+ * Fills every slot in the list with the specified value.
+ *
+ * @param val the value to use when filling
+ */
+ public void fill( byte val );
+
+
+ /**
+ * Fills a range in the list with the specified value.
+ *
+ * @param fromIndex the offset at which to start filling (inclusive)
+ * @param toIndex the offset at which to stop filling (exclusive)
+ * @param val the value to use when filling
+ */
+ public void fill( int fromIndex, int toIndex, byte val );
+
+
+ /**
+ * Performs a binary search for value in the entire list.
+ * Note that you must @{link #sort sort} the list before
+ * doing a search.
+ *
+ * @param value the value to search for
+ * @return the absolute offset in the list of the value, or its
+ * negative insertion point into the sorted list.
+ */
+ public int binarySearch( byte value );
+
+
+ /**
+ * Performs a binary search for value in the specified
+ * range. Note that you must @{link #sort sort} the list
+ * or the range before doing a search.
+ *
+ * @param value the value to search for
+ * @param fromIndex the lower boundary of the range (inclusive)
+ * @param toIndex the upper boundary of the range (exclusive)
+ * @return the absolute offset in the list of the value, or its
+ * negative insertion point into the sorted list.
+ */
+ public int binarySearch( byte value, int fromIndex, int toIndex );
+
+
+ /**
+ * Searches the list front to back for the index of
+ * value.
+ *
+ * @param value an byte
value
+ * @return the first offset of the value, or -1 if it is not in
+ * the list.
+ * @see #binarySearch for faster searches on sorted lists
+ */
+ public int indexOf( byte value );
+
+
+ /**
+ * Searches the list front to back for the index of
+ * value, starting at offset.
+ *
+ * @param offset the offset at which to start the linear search
+ * (inclusive)
+ * @param value an byte
value
+ * @return the first offset of the value, or -1 if it is not in
+ * the list.
+ * @see #binarySearch for faster searches on sorted lists
+ */
+ public int indexOf( int offset, byte value );
+
+
+ /**
+ * Searches the list back to front for the last index of
+ * value.
+ *
+ * @param value an byte
value
+ * @return the last offset of the value, or -1 if it is not in
+ * the list.
+ * @see #binarySearch for faster searches on sorted lists
+ */
+ public int lastIndexOf( byte value );
+
+
+ /**
+ * Searches the list back to front for the last index of
+ * value, starting at offset.
+ *
+ * @param offset the offset at which to start the linear search
+ * (exclusive)
+ * @param value an byte
value
+ * @return the last offset of the value, or -1 if it is not in
+ * the list.
+ * @see #binarySearch for faster searches on sorted lists
+ */
+ public int lastIndexOf( int offset, byte value );
+
+
+ /**
+ * Searches the list for value
+ *
+ * @param value an byte
value
+ * @return true if value is in the list.
+ */
+ @Override
+ public boolean contains( byte value );
+
+
+ /**
+ * Searches the list for values satisfying condition in
+ * the manner of the *nix grep utility.
+ *
+ * @param condition a condition to apply to each element in the list
+ * @return a list of values which match the condition.
+ */
+ public TByteList grep( TByteProcedure condition );
+
+
+ /**
+ * Searches the list for values which do not satisfy
+ * condition. This is akin to *nix grep -v
.
+ *
+ * @param condition a condition to apply to each element in the list
+ * @return a list of values which do not match the condition.
+ */
+ public TByteList inverseGrep( TByteProcedure condition );
+
+
+ /**
+ * Finds the maximum value in the list.
+ *
+ * @return the largest value in the list.
+ * @exception IllegalStateException if the list is empty
+ */
+ public byte max();
+
+
+ /**
+ * Finds the minimum value in the list.
+ *
+ * @return the smallest value in the list.
+ * @exception IllegalStateException if the list is empty
+ */
+ public byte min();
+}
diff --git a/DataExtractionOSM/src/gnu/trove/list/array/TByteArrayList.java b/DataExtractionOSM/src/gnu/trove/list/array/TByteArrayList.java
new file mode 100644
index 0000000000..897171e5ca
--- /dev/null
+++ b/DataExtractionOSM/src/gnu/trove/list/array/TByteArrayList.java
@@ -0,0 +1,1079 @@
+///////////////////////////////////////////////////////////////////////////////
+// Copyright (c) 2001, Eric D. Friedman All Rights Reserved.
+// Copyright (c) 2009, Rob Eden All Rights Reserved.
+// Copyright (c) 2009, Jeff Randall All Rights Reserved.
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this program; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+///////////////////////////////////////////////////////////////////////////////
+
+package gnu.trove.list.array;
+
+import gnu.trove.function.TByteFunction;
+import gnu.trove.list.TByteList;
+import gnu.trove.procedure.TByteProcedure;
+import gnu.trove.iterator.TByteIterator;
+import gnu.trove.TByteCollection;
+import gnu.trove.impl.*;
+
+import java.io.Externalizable;
+import java.io.IOException;
+import java.io.ObjectInput;
+import java.io.ObjectOutput;
+import java.util.*;
+
+
+//////////////////////////////////////////////////
+// THIS IS A GENERATED CLASS. DO NOT HAND EDIT! //
+//////////////////////////////////////////////////
+
+
+/**
+ * A resizable, array-backed list of byte primitives.
+ */
+public class TByteArrayList implements TByteList, Externalizable {
+ static final long serialVersionUID = 1L;
+
+ /** the data of the list */
+ protected byte[] _data;
+
+ /** the index after the last entry in the list */
+ protected int _pos;
+
+ /** the default capacity for new lists */
+ protected static final int DEFAULT_CAPACITY = Constants.DEFAULT_CAPACITY;
+
+ /** the byte value that represents null */
+ protected byte no_entry_value;
+
+
+ /**
+ * Creates a new TByteArrayList
instance with the
+ * default capacity.
+ */
+ @SuppressWarnings({"RedundantCast"})
+ public TByteArrayList() {
+ this( DEFAULT_CAPACITY, ( byte ) 0 );
+ }
+
+
+ /**
+ * Creates a new TByteArrayList
instance with the
+ * specified capacity.
+ *
+ * @param capacity an int
value
+ */
+ @SuppressWarnings({"RedundantCast"})
+ public TByteArrayList( int capacity ) {
+ this( capacity, ( byte ) 0 );
+ }
+
+
+ /**
+ * Creates a new TByteArrayList
instance with the
+ * specified capacity.
+ *
+ * @param capacity an int
value
+ * @param no_entry_value an byte
value that represents null.
+ */
+ public TByteArrayList( int capacity, byte no_entry_value ) {
+ _data = new byte[ capacity ];
+ _pos = 0;
+ this.no_entry_value = no_entry_value;
+ }
+
+ /**
+ * Creates a new TByteArrayList
instance that contains
+ * a copy of the collection passed to us.
+ *
+ * @param collection the collection to copy
+ */
+ public TByteArrayList ( TByteCollection collection ) {
+ this( collection.size() );
+ addAll( collection );
+ }
+
+
+ /**
+ * Creates a new TByteArrayList
instance whose
+ * capacity is the length of values array and whose
+ * initial contents are the specified values.
+ *
+ * @param values an byte[]
value
+ */
+ public TByteArrayList( byte[] values ) {
+ this( values.length );
+ add( values );
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public byte getNoEntryValue() {
+ return no_entry_value;
+ }
+
+
+ // sizing
+
+ /**
+ * Grow the internal array as needed to accommodate the specified number of elements.
+ * The size of the array bytes on each resize unless capacity requires more than twice
+ * the current capacity.
+ */
+ public void ensureCapacity( int capacity ) {
+ if ( capacity > _data.length ) {
+ int newCap = Math.max( _data.length << 1, capacity );
+ byte[] tmp = new byte[ newCap ];
+ System.arraycopy( _data, 0, tmp, 0, _data.length );
+ _data = tmp;
+ }
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public int size() {
+ return _pos;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean isEmpty() {
+ return _pos == 0;
+ }
+
+
+ /**
+ * Sheds any excess capacity above and beyond the current size of the list.
+ */
+ public void trimToSize() {
+ if ( _data.length > size() ) {
+ byte[] tmp = new byte[ size() ];
+ toArray( tmp, 0, tmp.length );
+ _data = tmp;
+ }
+ }
+
+
+ // modifying
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean add( byte val ) {
+ ensureCapacity( _pos + 1 );
+ _data[ _pos++ ] = val;
+ return true;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void add( byte[] vals ) {
+ add( vals, 0, vals.length );
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void add( byte[] vals, int offset, int length ) {
+ ensureCapacity( _pos + length );
+ System.arraycopy( vals, offset, _data, _pos, length );
+ _pos += length;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void insert( int offset, byte value ) {
+ if ( offset == _pos ) {
+ add( value );
+ return;
+ }
+ ensureCapacity( _pos + 1 );
+ // shift right
+ System.arraycopy( _data, offset, _data, offset + 1, _pos - offset );
+ // insert
+ _data[ offset ] = value;
+ _pos++;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void insert( int offset, byte[] values ) {
+ insert( offset, values, 0, values.length );
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void insert( int offset, byte[] values, int valOffset, int len ) {
+ if ( offset == _pos ) {
+ add( values, valOffset, len );
+ return;
+ }
+
+ ensureCapacity( _pos + len );
+ // shift right
+ System.arraycopy( _data, offset, _data, offset + len, _pos - offset );
+ // insert
+ System.arraycopy( values, valOffset, _data, offset, len );
+ _pos += len;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public byte get( int offset ) {
+ if ( offset >= _pos ) {
+ throw new ArrayIndexOutOfBoundsException( offset );
+ }
+ return _data[ offset ];
+ }
+
+
+ /**
+ * Returns the value at the specified offset without doing any bounds checking.
+ */
+ public byte getQuick( int offset ) {
+ return _data[ offset ];
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public byte set( int offset, byte val ) {
+ if ( offset >= _pos ) {
+ throw new ArrayIndexOutOfBoundsException( offset );
+ }
+
+ byte prev_val = _data[ offset ];
+ _data[ offset ] = val;
+ return prev_val;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public byte replace( int offset, byte val ) {
+ if ( offset >= _pos ) {
+ throw new ArrayIndexOutOfBoundsException( offset );
+ }
+ byte old = _data[ offset ];
+ _data[ offset ] = val;
+ return old;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void set( int offset, byte[] values ) {
+ set( offset, values, 0, values.length );
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void set( int offset, byte[] values, int valOffset, int length ) {
+ if ( offset < 0 || offset + length > _pos ) {
+ throw new ArrayIndexOutOfBoundsException( offset );
+ }
+ System.arraycopy( values, valOffset, _data, offset, length );
+ }
+
+
+ /**
+ * Sets the value at the specified offset without doing any bounds checking.
+ */
+ public void setQuick( int offset, byte val ) {
+ _data[ offset ] = val;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void clear() {
+ clear( DEFAULT_CAPACITY );
+ }
+
+
+ /**
+ * Flushes the internal state of the list, setting the capacity of the empty list to
+ * capacity.
+ */
+ public void clear( int capacity ) {
+ _data = new byte[ capacity ];
+ _pos = 0;
+ }
+
+
+ /**
+ * Sets the size of the list to 0, but does not change its capacity. This method can
+ * be used as an alternative to the {@link #clear()} method if you want to recycle a
+ * list without allocating new backing arrays.
+ */
+ public void reset() {
+ _pos = 0;
+ Arrays.fill( _data, no_entry_value );
+ }
+
+
+ /**
+ * Sets the size of the list to 0, but does not change its capacity. This method can
+ * be used as an alternative to the {@link #clear()} method if you want to recycle a
+ * list without allocating new backing arrays. This method differs from
+ * {@link #reset()} in that it does not clear the old values in the backing array.
+ * Thus, it is possible for getQuick to return stale data if this method is used and
+ * the caller is careless about bounds checking.
+ */
+ public void resetQuick() {
+ _pos = 0;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean remove( byte value ) {
+ for ( int index = 0; index < _pos; index++ ) {
+ if ( value == _data[index] ) {
+ remove( index, 1 );
+ return true;
+ }
+ }
+ return false;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public byte removeAt( int offset ) {
+ byte old = get( offset );
+ remove( offset, 1 );
+ return old;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void remove( int offset, int length ) {
+ if ( offset < 0 || offset >= _pos ) {
+ throw new ArrayIndexOutOfBoundsException(offset);
+ }
+
+ if ( offset == 0 ) {
+ // data at the front
+ System.arraycopy( _data, length, _data, 0, _pos - length );
+ }
+ else if ( _pos - length == offset ) {
+ // no copy to make, decrementing pos "deletes" values at
+ // the end
+ }
+ else {
+ // data in the middle
+ System.arraycopy( _data, offset + length, _data, offset,
+ _pos - ( offset + length ) );
+ }
+ _pos -= length;
+ // no need to clear old values beyond _pos, because this is a
+ // primitive collection and 0 takes as much room as any other
+ // value
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public TByteIterator iterator() {
+ return new TByteArrayIterator( 0 );
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean containsAll( Collection> collection ) {
+ for ( Object element : collection ) {
+ if ( element instanceof Byte ) {
+ byte c = ( ( Byte ) element ).byteValue();
+ if ( ! contains( c ) ) {
+ return false;
+ }
+ } else {
+ return false;
+ }
+
+ }
+ return true;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean containsAll( TByteCollection collection ) {
+ if ( this == collection ) {
+ return true;
+ }
+ TByteIterator iter = collection.iterator();
+ while ( iter.hasNext() ) {
+ byte element = iter.next();
+ if ( ! contains( element ) ) {
+ return false;
+ }
+ }
+ return true;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean containsAll( byte[] array ) {
+ for ( int i = array.length; i-- > 0; ) {
+ if ( ! contains( array[i] ) ) {
+ return false;
+ }
+ }
+ return true;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean addAll( Collection extends Byte> collection ) {
+ boolean changed = false;
+ for ( Byte element : collection ) {
+ byte e = element.byteValue();
+ if ( add( e ) ) {
+ changed = true;
+ }
+ }
+ return changed;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean addAll( TByteCollection collection ) {
+ boolean changed = false;
+ TByteIterator iter = collection.iterator();
+ while ( iter.hasNext() ) {
+ byte element = iter.next();
+ if ( add( element ) ) {
+ changed = true;
+ }
+ }
+ return changed;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean addAll( byte[] array ) {
+ boolean changed = false;
+ for ( byte element : array ) {
+ if ( add( element ) ) {
+ changed = true;
+ }
+ }
+ return changed;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ @SuppressWarnings({"SuspiciousMethodCalls"})
+ public boolean retainAll( Collection> collection ) {
+ boolean modified = false;
+ TByteIterator iter = iterator();
+ while ( iter.hasNext() ) {
+ if ( ! collection.contains( Byte.valueOf ( iter.next() ) ) ) {
+ iter.remove();
+ modified = true;
+ }
+ }
+ return modified;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean retainAll( TByteCollection collection ) {
+ if ( this == collection ) {
+ return false;
+ }
+ boolean modified = false;
+ TByteIterator iter = iterator();
+ while ( iter.hasNext() ) {
+ if ( ! collection.contains( iter.next() ) ) {
+ iter.remove();
+ modified = true;
+ }
+ }
+ return modified;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean retainAll( byte[] array ) {
+ boolean changed = false;
+ Arrays.sort( array );
+ byte[] data = _data;
+
+ for ( int i = data.length; i-- > 0; ) {
+ if ( Arrays.binarySearch( array, data[i] ) < 0 ) {
+ remove( i, 1 );
+ changed = true;
+ }
+ }
+ return changed;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean removeAll( Collection> collection ) {
+ boolean changed = false;
+ for ( Object element : collection ) {
+ if ( element instanceof Byte ) {
+ byte c = ( ( Byte ) element ).byteValue();
+ if ( remove( c ) ) {
+ changed = true;
+ }
+ }
+ }
+ return changed;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean removeAll( TByteCollection collection ) {
+ if ( collection == this ) {
+ clear();
+ return true;
+ }
+ boolean changed = false;
+ TByteIterator iter = collection.iterator();
+ while ( iter.hasNext() ) {
+ byte element = iter.next();
+ if ( remove( element ) ) {
+ changed = true;
+ }
+ }
+ return changed;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean removeAll( byte[] array ) {
+ boolean changed = false;
+ for ( int i = array.length; i-- > 0; ) {
+ if ( remove(array[i]) ) {
+ changed = true;
+ }
+ }
+ return changed;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void transformValues( TByteFunction function ) {
+ for ( int i = _pos; i-- > 0; ) {
+ _data[ i ] = function.execute( _data[ i ] );
+ }
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void reverse() {
+ reverse( 0, _pos );
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void reverse( int from, int to ) {
+ if ( from == to ) {
+ return; // nothing to do
+ }
+ if ( from > to ) {
+ throw new IllegalArgumentException( "from cannot be greater than to" );
+ }
+ for ( int i = from, j = to - 1; i < j; i++, j-- ) {
+ swap( i, j );
+ }
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void shuffle( Random rand ) {
+ for ( int i = _pos; i-- > 1; ) {
+ swap( i, rand.nextInt( i ) );
+ }
+ }
+
+
+ /**
+ * Swap the values at offsets i and j.
+ *
+ * @param i an offset into the data array
+ * @param j an offset into the data array
+ */
+ private void swap( int i, int j ) {
+ byte tmp = _data[ i ];
+ _data[ i ] = _data[ j ];
+ _data[ j ] = tmp;
+ }
+
+
+ // copying
+
+ /** {@inheritDoc} */
+ @Override
+ public TByteList subList( int begin, int end ) {
+ if ( end < begin ) {
+ throw new IllegalArgumentException( "end index " + end +
+ " greater than begin index " + begin );
+ }
+ if ( begin < 0 ) {
+ throw new IndexOutOfBoundsException( "begin index can not be < 0" );
+ }
+ if ( end > _data.length ) {
+ throw new IndexOutOfBoundsException( "end index < " + _data.length );
+ }
+ TByteArrayList list = new TByteArrayList( end - begin );
+ for ( int i = begin; i < end; i++ ) {
+ list.add( _data[ i ] );
+ }
+ return list;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public byte[] toArray() {
+ return toArray( 0, _pos );
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public byte[] toArray( int offset, int len ) {
+ byte[] rv = new byte[ len ];
+ toArray( rv, offset, len );
+ return rv;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public byte[] toArray( byte[] dest ) {
+ int len = dest.length;
+ if ( dest.length > _pos ) {
+ len = _pos;
+ dest[len] = no_entry_value;
+ }
+ toArray( dest, 0, len );
+ return dest;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public byte[] toArray( byte[] dest, int offset, int len ) {
+ if ( len == 0 ) {
+ return dest; // nothing to copy
+ }
+ if ( offset < 0 || offset >= _pos ) {
+ throw new ArrayIndexOutOfBoundsException( offset );
+ }
+ System.arraycopy( _data, offset, dest, 0, len );
+ return dest;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public byte[] toArray( byte[] dest, int source_pos, int dest_pos, int len ) {
+ if ( len == 0 ) {
+ return dest; // nothing to copy
+ }
+ if ( source_pos < 0 || source_pos >= _pos ) {
+ throw new ArrayIndexOutOfBoundsException( source_pos );
+ }
+ System.arraycopy( _data, source_pos, dest, dest_pos, len );
+ return dest;
+ }
+
+
+ // comparing
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean equals( Object other ) {
+ if ( other == this ) {
+ return true;
+ }
+ else if ( other instanceof TByteArrayList ) {
+ TByteArrayList that = ( TByteArrayList )other;
+ if ( that.size() != this.size() ) return false;
+ else {
+ for ( int i = _pos; i-- > 0; ) {
+ if ( this._data[ i ] != that._data[ i ] ) {
+ return false;
+ }
+ }
+ return true;
+ }
+ }
+ else return false;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public int hashCode() {
+ int h = 0;
+ for ( int i = _pos; i-- > 0; ) {
+ h += HashFunctions.hash( _data[ i ] );
+ }
+ return h;
+ }
+
+
+ // procedures
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean forEach( TByteProcedure procedure ) {
+ for ( int i = 0; i < _pos; i++ ) {
+ if ( !procedure.execute( _data[ i ] ) ) {
+ return false;
+ }
+ }
+ return true;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean forEachDescending( TByteProcedure procedure ) {
+ for ( int i = _pos; i-- > 0; ) {
+ if ( !procedure.execute( _data[ i ] ) ) {
+ return false;
+ }
+ }
+ return true;
+ }
+
+
+ // sorting
+
+ /** {@inheritDoc} */
+ @Override
+ public void sort() {
+ Arrays.sort( _data, 0, _pos );
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void sort( int fromIndex, int toIndex ) {
+ Arrays.sort( _data, fromIndex, toIndex );
+ }
+
+
+ // filling
+
+ /** {@inheritDoc} */
+ @Override
+ public void fill( byte val ) {
+ Arrays.fill( _data, 0, _pos, val );
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void fill( int fromIndex, int toIndex, byte val ) {
+ if ( toIndex > _pos ) {
+ ensureCapacity( toIndex );
+ _pos = toIndex;
+ }
+ Arrays.fill( _data, fromIndex, toIndex, val );
+ }
+
+
+ // searching
+
+ /** {@inheritDoc} */
+ @Override
+ public int binarySearch( byte value ) {
+ return binarySearch( value, 0, _pos );
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public int binarySearch(byte value, int fromIndex, int toIndex) {
+ if ( fromIndex < 0 ) {
+ throw new ArrayIndexOutOfBoundsException( fromIndex );
+ }
+ if ( toIndex > _pos ) {
+ throw new ArrayIndexOutOfBoundsException( toIndex );
+ }
+
+ int low = fromIndex;
+ int high = toIndex - 1;
+
+ while ( low <= high ) {
+ int mid = ( low + high ) >>> 1;
+ byte midVal = _data[ mid ];
+
+ if ( midVal < value ) {
+ low = mid + 1;
+ }
+ else if ( midVal > value ) {
+ high = mid - 1;
+ }
+ else {
+ return mid; // value found
+ }
+ }
+ return -( low + 1 ); // value not found.
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public int indexOf( byte value ) {
+ return indexOf( 0, value );
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public int indexOf( int offset, byte value ) {
+ for ( int i = offset; i < _pos; i++ ) {
+ if ( _data[ i ] == value ) {
+ return i;
+ }
+ }
+ return -1;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public int lastIndexOf( byte value ) {
+ return lastIndexOf( _pos, value );
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public int lastIndexOf( int offset, byte value ) {
+ for ( int i = offset; i-- > 0; ) {
+ if ( _data[ i ] == value ) {
+ return i;
+ }
+ }
+ return -1;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean contains( byte value ) {
+ return lastIndexOf( value ) >= 0;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public TByteList grep( TByteProcedure condition ) {
+ TByteArrayList list = new TByteArrayList();
+ for ( int i = 0; i < _pos; i++ ) {
+ if ( condition.execute( _data[ i ] ) ) {
+ list.add( _data[ i ] );
+ }
+ }
+ return list;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public TByteList inverseGrep( TByteProcedure condition ) {
+ TByteArrayList list = new TByteArrayList();
+ for ( int i = 0; i < _pos; i++ ) {
+ if ( !condition.execute( _data[ i ] ) ) {
+ list.add( _data[ i ] );
+ }
+ }
+ return list;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public byte max() {
+ if ( size() == 0 ) {
+ throw new IllegalStateException("cannot find maximum of an empty list");
+ }
+ byte max = Byte.MIN_VALUE;
+ for ( int i = 0; i < _pos; i++ ) {
+ if ( _data[ i ] > max ) {
+ max = _data[ i ];
+ }
+ }
+ return max;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public byte min() {
+ if ( size() == 0 ) {
+ throw new IllegalStateException( "cannot find minimum of an empty list" );
+ }
+ byte min = Byte.MAX_VALUE;
+ for ( int i = 0; i < _pos; i++ ) {
+ if ( _data[i] < min ) {
+ min = _data[i];
+ }
+ }
+ return min;
+ }
+
+
+ // stringification
+
+ /** {@inheritDoc} */
+ @Override
+ public String toString() {
+ final StringBuilder buf = new StringBuilder( "{" );
+ for ( int i = 0, end = _pos - 1; i < end; i++ ) {
+ buf.append( _data[ i ] );
+ buf.append( ", " );
+ }
+ if ( size() > 0 ) {
+ buf.append( _data[ _pos - 1 ] );
+ }
+ buf.append( "}" );
+ return buf.toString();
+ }
+
+
+ /** TByteArrayList iterator */
+ class TByteArrayIterator implements TByteIterator {
+
+ /** Index of element to be returned by subsequent call to next. */
+ private int cursor = 0;
+
+ /**
+ * Index of element returned by most recent call to next or
+ * previous. Reset to -1 if this element is deleted by a call
+ * to remove.
+ */
+ int lastRet = -1;
+
+
+ TByteArrayIterator( int index ) {
+ cursor = index;
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public boolean hasNext() {
+ return cursor < size();
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public byte next() {
+ try {
+ byte next = get( cursor );
+ lastRet = cursor++;
+ return next;
+ } catch ( IndexOutOfBoundsException e ) {
+ throw new NoSuchElementException();
+ }
+ }
+
+
+ /** {@inheritDoc} */
+ @Override
+ public void remove() {
+ if ( lastRet == -1 )
+ throw new IllegalStateException();
+
+ try {
+ TByteArrayList.this.remove( lastRet, 1);
+ if ( lastRet < cursor )
+ cursor--;
+ lastRet = -1;
+ } catch ( IndexOutOfBoundsException e ) {
+ throw new ConcurrentModificationException();
+ }
+ }
+ }
+
+
+ @Override
+ public void writeExternal( ObjectOutput out ) throws IOException {
+ // VERSION
+ out.writeByte( 0 );
+
+ // POSITION
+ out.writeInt( _pos );
+
+ // NO_ENTRY_VALUE
+ out.writeByte( no_entry_value );
+
+ // ENTRIES
+ int len = _data.length;
+ out.writeInt( len );
+ for( int i = 0; i < len; i++ ) {
+ out.writeByte( _data[ i ] );
+ }
+ }
+
+
+ @Override
+ public void readExternal( ObjectInput in )
+ throws IOException, ClassNotFoundException {
+
+ // VERSION
+ in.readByte();
+
+ // POSITION
+ _pos = in.readInt();
+
+ // NO_ENTRY_VALUE
+ no_entry_value = in.readByte();
+
+ // ENTRIES
+ int len = in.readInt();
+ _data = new byte[ len ];
+ for( int i = 0; i < len; i++ ) {
+ _data[ i ] = in.readByte();
+ }
+ }
+} // TByteArrayList
diff --git a/DataExtractionOSM/src/net/osmand/binary/OsmandOdb.java b/DataExtractionOSM/src/net/osmand/binary/OsmandOdb.java
index b840c4de32..26e4e37f6e 100644
--- a/DataExtractionOSM/src/net/osmand/binary/OsmandOdb.java
+++ b/DataExtractionOSM/src/net/osmand/binary/OsmandOdb.java
@@ -8,67 +8,11 @@ public final class OsmandOdb {
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistry registry) {
}
- public interface OsmAndStructureOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // required uint32 version = 1;
- boolean hasVersion();
- int getVersion();
-
- // required int64 dateCreated = 18;
- boolean hasDateCreated();
- long getDateCreated();
-
- // repeated .OsmAndAddressIndex addressIndex = 7;
- java.util.List
- getAddressIndexList();
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex getAddressIndex(int index);
- int getAddressIndexCount();
- java.util.List extends net.osmand.binary.OsmandOdb.OsmAndAddressIndexOrBuilder>
- getAddressIndexOrBuilderList();
- net.osmand.binary.OsmandOdb.OsmAndAddressIndexOrBuilder getAddressIndexOrBuilder(
- int index);
-
- // repeated .OsmAndTransportIndex transportIndex = 4;
- java.util.List
- getTransportIndexList();
- net.osmand.binary.OsmandOdb.OsmAndTransportIndex getTransportIndex(int index);
- int getTransportIndexCount();
- java.util.List extends net.osmand.binary.OsmandOdb.OsmAndTransportIndexOrBuilder>
- getTransportIndexOrBuilderList();
- net.osmand.binary.OsmandOdb.OsmAndTransportIndexOrBuilder getTransportIndexOrBuilder(
- int index);
-
- // repeated .OsmAndPoiIndex poiIndex = 8;
- java.util.List
- getPoiIndexList();
- net.osmand.binary.OsmandOdb.OsmAndPoiIndex getPoiIndex(int index);
- int getPoiIndexCount();
- java.util.List extends net.osmand.binary.OsmandOdb.OsmAndPoiIndexOrBuilder>
- getPoiIndexOrBuilderList();
- net.osmand.binary.OsmandOdb.OsmAndPoiIndexOrBuilder getPoiIndexOrBuilder(
- int index);
-
- // repeated .OsmAndMapIndex mapIndex = 6;
- java.util.List
- getMapIndexList();
- net.osmand.binary.OsmandOdb.OsmAndMapIndex getMapIndex(int index);
- int getMapIndexCount();
- java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndexOrBuilder>
- getMapIndexOrBuilderList();
- net.osmand.binary.OsmandOdb.OsmAndMapIndexOrBuilder getMapIndexOrBuilder(
- int index);
-
- // required uint32 versionConfirm = 32;
- boolean hasVersionConfirm();
- int getVersionConfirm();
- }
public static final class OsmAndStructure extends
- com.google.protobuf.GeneratedMessage
- implements OsmAndStructureOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use OsmAndStructure.newBuilder() to construct.
- private OsmAndStructure(Builder builder) {
- super(builder);
+ private OsmAndStructure() {
+ initFields();
}
private OsmAndStructure(boolean noInit) {}
@@ -77,7 +21,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public OsmAndStructure getDefaultInstanceForType() {
+ @Override
+ public OsmAndStructure getDefaultInstanceForType() {
return defaultInstance;
}
@@ -86,253 +31,171 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndStructure_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndStructure_fieldAccessorTable;
}
- private int bitField0_;
// required uint32 version = 1;
public static final int VERSION_FIELD_NUMBER = 1;
- private int version_;
- public boolean hasVersion() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
- }
- public int getVersion() {
- return version_;
- }
+ private boolean hasVersion;
+ private int version_ = 0;
+ public boolean hasVersion() { return hasVersion; }
+ public int getVersion() { return version_; }
// required int64 dateCreated = 18;
public static final int DATECREATED_FIELD_NUMBER = 18;
- private long dateCreated_;
- public boolean hasDateCreated() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
- }
- public long getDateCreated() {
- return dateCreated_;
- }
+ private boolean hasDateCreated;
+ private long dateCreated_ = 0L;
+ public boolean hasDateCreated() { return hasDateCreated; }
+ public long getDateCreated() { return dateCreated_; }
// repeated .OsmAndAddressIndex addressIndex = 7;
public static final int ADDRESSINDEX_FIELD_NUMBER = 7;
- private java.util.List addressIndex_;
+ private java.util.List addressIndex_ =
+ java.util.Collections.emptyList();
public java.util.List getAddressIndexList() {
return addressIndex_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndAddressIndexOrBuilder>
- getAddressIndexOrBuilderList() {
- return addressIndex_;
- }
- public int getAddressIndexCount() {
- return addressIndex_.size();
- }
+ public int getAddressIndexCount() { return addressIndex_.size(); }
public net.osmand.binary.OsmandOdb.OsmAndAddressIndex getAddressIndex(int index) {
return addressIndex_.get(index);
}
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndexOrBuilder getAddressIndexOrBuilder(
- int index) {
- return addressIndex_.get(index);
- }
// repeated .OsmAndTransportIndex transportIndex = 4;
public static final int TRANSPORTINDEX_FIELD_NUMBER = 4;
- private java.util.List transportIndex_;
+ private java.util.List transportIndex_ =
+ java.util.Collections.emptyList();
public java.util.List getTransportIndexList() {
return transportIndex_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndTransportIndexOrBuilder>
- getTransportIndexOrBuilderList() {
- return transportIndex_;
- }
- public int getTransportIndexCount() {
- return transportIndex_.size();
- }
+ public int getTransportIndexCount() { return transportIndex_.size(); }
public net.osmand.binary.OsmandOdb.OsmAndTransportIndex getTransportIndex(int index) {
return transportIndex_.get(index);
}
- public net.osmand.binary.OsmandOdb.OsmAndTransportIndexOrBuilder getTransportIndexOrBuilder(
- int index) {
- return transportIndex_.get(index);
- }
// repeated .OsmAndPoiIndex poiIndex = 8;
public static final int POIINDEX_FIELD_NUMBER = 8;
- private java.util.List poiIndex_;
+ private java.util.List poiIndex_ =
+ java.util.Collections.emptyList();
public java.util.List getPoiIndexList() {
return poiIndex_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndPoiIndexOrBuilder>
- getPoiIndexOrBuilderList() {
- return poiIndex_;
- }
- public int getPoiIndexCount() {
- return poiIndex_.size();
- }
+ public int getPoiIndexCount() { return poiIndex_.size(); }
public net.osmand.binary.OsmandOdb.OsmAndPoiIndex getPoiIndex(int index) {
return poiIndex_.get(index);
}
- public net.osmand.binary.OsmandOdb.OsmAndPoiIndexOrBuilder getPoiIndexOrBuilder(
- int index) {
- return poiIndex_.get(index);
- }
// repeated .OsmAndMapIndex mapIndex = 6;
public static final int MAPINDEX_FIELD_NUMBER = 6;
- private java.util.List mapIndex_;
+ private java.util.List mapIndex_ =
+ java.util.Collections.emptyList();
public java.util.List getMapIndexList() {
return mapIndex_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndexOrBuilder>
- getMapIndexOrBuilderList() {
- return mapIndex_;
- }
- public int getMapIndexCount() {
- return mapIndex_.size();
- }
+ public int getMapIndexCount() { return mapIndex_.size(); }
public net.osmand.binary.OsmandOdb.OsmAndMapIndex getMapIndex(int index) {
return mapIndex_.get(index);
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndexOrBuilder getMapIndexOrBuilder(
- int index) {
- return mapIndex_.get(index);
- }
// required uint32 versionConfirm = 32;
public static final int VERSIONCONFIRM_FIELD_NUMBER = 32;
- private int versionConfirm_;
- public boolean hasVersionConfirm() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
- }
- public int getVersionConfirm() {
- return versionConfirm_;
- }
+ private boolean hasVersionConfirm;
+ private int versionConfirm_ = 0;
+ public boolean hasVersionConfirm() { return hasVersionConfirm; }
+ public int getVersionConfirm() { return versionConfirm_; }
private void initFields() {
- version_ = 0;
- dateCreated_ = 0L;
- addressIndex_ = java.util.Collections.emptyList();
- transportIndex_ = java.util.Collections.emptyList();
- poiIndex_ = java.util.Collections.emptyList();
- mapIndex_ = java.util.Collections.emptyList();
- versionConfirm_ = 0;
}
- private byte memoizedIsInitialized = -1;
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized != -1) return isInitialized == 1;
-
- if (!hasVersion()) {
- memoizedIsInitialized = 0;
- return false;
+ @Override
+ public final boolean isInitialized() {
+ if (!hasVersion) return false;
+ if (!hasDateCreated) return false;
+ if (!hasVersionConfirm) return false;
+ for (net.osmand.binary.OsmandOdb.OsmAndAddressIndex element : getAddressIndexList()) {
+ if (!element.isInitialized()) return false;
}
- if (!hasDateCreated()) {
- memoizedIsInitialized = 0;
- return false;
+ for (net.osmand.binary.OsmandOdb.OsmAndTransportIndex element : getTransportIndexList()) {
+ if (!element.isInitialized()) return false;
}
- if (!hasVersionConfirm()) {
- memoizedIsInitialized = 0;
- return false;
+ for (net.osmand.binary.OsmandOdb.OsmAndPoiIndex element : getPoiIndexList()) {
+ if (!element.isInitialized()) return false;
}
- for (int i = 0; i < getAddressIndexCount(); i++) {
- if (!getAddressIndex(i).isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex element : getMapIndexList()) {
+ if (!element.isInitialized()) return false;
}
- for (int i = 0; i < getTransportIndexCount(); i++) {
- if (!getTransportIndex(i).isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
- }
- for (int i = 0; i < getPoiIndexCount(); i++) {
- if (!getPoiIndex(i).isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
- }
- for (int i = 0; i < getMapIndexCount(); i++) {
- if (!getMapIndex(i).isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
- }
- memoizedIsInitialized = 1;
return true;
}
- public void writeTo(com.google.protobuf.CodedOutputStream output)
+ @Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
- output.writeUInt32(1, version_);
+ if (hasVersion()) {
+ output.writeUInt32(1, getVersion());
}
- for (int i = 0; i < transportIndex_.size(); i++) {
- output.writeMessage(4, transportIndex_.get(i));
+ for (net.osmand.binary.OsmandOdb.OsmAndTransportIndex element : getTransportIndexList()) {
+ output.writeMessage(4, element);
}
- for (int i = 0; i < mapIndex_.size(); i++) {
- output.writeMessage(6, mapIndex_.get(i));
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex element : getMapIndexList()) {
+ output.writeMessage(6, element);
}
- for (int i = 0; i < addressIndex_.size(); i++) {
- output.writeMessage(7, addressIndex_.get(i));
+ for (net.osmand.binary.OsmandOdb.OsmAndAddressIndex element : getAddressIndexList()) {
+ output.writeMessage(7, element);
}
- for (int i = 0; i < poiIndex_.size(); i++) {
- output.writeMessage(8, poiIndex_.get(i));
+ for (net.osmand.binary.OsmandOdb.OsmAndPoiIndex element : getPoiIndexList()) {
+ output.writeMessage(8, element);
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
- output.writeInt64(18, dateCreated_);
+ if (hasDateCreated()) {
+ output.writeInt64(18, getDateCreated());
}
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
- output.writeUInt32(32, versionConfirm_);
+ if (hasVersionConfirm()) {
+ output.writeUInt32(32, getVersionConfirm());
}
getUnknownFields().writeTo(output);
}
private int memoizedSerializedSize = -1;
- public int getSerializedSize() {
+ @Override
+ public int getSerializedSize() {
int size = memoizedSerializedSize;
if (size != -1) return size;
size = 0;
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ if (hasVersion()) {
size += com.google.protobuf.CodedOutputStream
- .computeUInt32Size(1, version_);
+ .computeUInt32Size(1, getVersion());
}
- for (int i = 0; i < transportIndex_.size(); i++) {
+ for (net.osmand.binary.OsmandOdb.OsmAndTransportIndex element : getTransportIndexList()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(4, transportIndex_.get(i));
+ .computeMessageSize(4, element);
}
- for (int i = 0; i < mapIndex_.size(); i++) {
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex element : getMapIndexList()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(6, mapIndex_.get(i));
+ .computeMessageSize(6, element);
}
- for (int i = 0; i < addressIndex_.size(); i++) {
+ for (net.osmand.binary.OsmandOdb.OsmAndAddressIndex element : getAddressIndexList()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(7, addressIndex_.get(i));
+ .computeMessageSize(7, element);
}
- for (int i = 0; i < poiIndex_.size(); i++) {
+ for (net.osmand.binary.OsmandOdb.OsmAndPoiIndex element : getPoiIndexList()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(8, poiIndex_.get(i));
+ .computeMessageSize(8, element);
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
+ if (hasDateCreated()) {
size += com.google.protobuf.CodedOutputStream
- .computeInt64Size(18, dateCreated_);
+ .computeInt64Size(18, getDateCreated());
}
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
+ if (hasVersionConfirm()) {
size += com.google.protobuf.CodedOutputStream
- .computeUInt32Size(32, versionConfirm_);
+ .computeUInt32Size(32, getVersionConfirm());
}
size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size;
return size;
}
- private static final long serialVersionUID = 0L;
- @java.lang.Override
- protected java.lang.Object writeReplace()
- throws java.io.ObjectStreamException {
- return super.writeReplace();
- }
-
public static net.osmand.binary.OsmandOdb.OsmAndStructure parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
@@ -401,176 +264,108 @@ public final class OsmandOdb {
}
public static Builder newBuilder() { return Builder.create(); }
- public Builder newBuilderForType() { return newBuilder(); }
+ @Override
+ public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder(net.osmand.binary.OsmandOdb.OsmAndStructure prototype) {
return newBuilder().mergeFrom(prototype);
}
- public Builder toBuilder() { return newBuilder(this); }
+ @Override
+ public Builder toBuilder() { return newBuilder(this); }
- @java.lang.Override
- protected Builder newBuilderForType(
- com.google.protobuf.GeneratedMessage.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
public static final class Builder extends
- com.google.protobuf.GeneratedMessage.Builder
- implements net.osmand.binary.OsmandOdb.OsmAndStructureOrBuilder {
- public static final com.google.protobuf.Descriptors.Descriptor
- getDescriptor() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndStructure_descriptor;
- }
-
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
- internalGetFieldAccessorTable() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndStructure_fieldAccessorTable;
- }
+ com.google.protobuf.GeneratedMessage.Builder {
+ private net.osmand.binary.OsmandOdb.OsmAndStructure result;
// Construct using net.osmand.binary.OsmandOdb.OsmAndStructure.newBuilder()
- private Builder() {
- maybeForceBuilderInitialization();
- }
+ private Builder() {}
- private Builder(BuilderParent parent) {
- super(parent);
- maybeForceBuilderInitialization();
- }
- private void maybeForceBuilderInitialization() {
- if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
- getAddressIndexFieldBuilder();
- getTransportIndexFieldBuilder();
- getPoiIndexFieldBuilder();
- getMapIndexFieldBuilder();
- }
- }
private static Builder create() {
- return new Builder();
+ Builder builder = new Builder();
+ builder.result = new net.osmand.binary.OsmandOdb.OsmAndStructure();
+ return builder;
}
- public Builder clear() {
- super.clear();
- version_ = 0;
- bitField0_ = (bitField0_ & ~0x00000001);
- dateCreated_ = 0L;
- bitField0_ = (bitField0_ & ~0x00000002);
- if (addressIndexBuilder_ == null) {
- addressIndex_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000004);
- } else {
- addressIndexBuilder_.clear();
+ @Override
+ protected net.osmand.binary.OsmandOdb.OsmAndStructure internalGetResult() {
+ return result;
+ }
+
+ @Override
+ public Builder clear() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "Cannot call clear() after build().");
}
- if (transportIndexBuilder_ == null) {
- transportIndex_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000008);
- } else {
- transportIndexBuilder_.clear();
- }
- if (poiIndexBuilder_ == null) {
- poiIndex_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000010);
- } else {
- poiIndexBuilder_.clear();
- }
- if (mapIndexBuilder_ == null) {
- mapIndex_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000020);
- } else {
- mapIndexBuilder_.clear();
- }
- versionConfirm_ = 0;
- bitField0_ = (bitField0_ & ~0x00000040);
+ result = new net.osmand.binary.OsmandOdb.OsmAndStructure();
return this;
}
- public Builder clone() {
- return create().mergeFrom(buildPartial());
+ @Override
+ public Builder clone() {
+ return create().mergeFrom(result);
}
- public com.google.protobuf.Descriptors.Descriptor
+ @Override
+ public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return net.osmand.binary.OsmandOdb.OsmAndStructure.getDescriptor();
}
- public net.osmand.binary.OsmandOdb.OsmAndStructure getDefaultInstanceForType() {
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndStructure getDefaultInstanceForType() {
return net.osmand.binary.OsmandOdb.OsmAndStructure.getDefaultInstance();
}
- public net.osmand.binary.OsmandOdb.OsmAndStructure build() {
- net.osmand.binary.OsmandOdb.OsmAndStructure result = buildPartial();
- if (!result.isInitialized()) {
+ @Override
+ public boolean isInitialized() {
+ return result.isInitialized();
+ }
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndStructure build() {
+ if (result != null && !isInitialized()) {
throw newUninitializedMessageException(result);
}
- return result;
+ return buildPartial();
}
private net.osmand.binary.OsmandOdb.OsmAndStructure buildParsed()
throws com.google.protobuf.InvalidProtocolBufferException {
- net.osmand.binary.OsmandOdb.OsmAndStructure result = buildPartial();
- if (!result.isInitialized()) {
+ if (!isInitialized()) {
throw newUninitializedMessageException(
result).asInvalidProtocolBufferException();
}
- return result;
+ return buildPartial();
}
- public net.osmand.binary.OsmandOdb.OsmAndStructure buildPartial() {
- net.osmand.binary.OsmandOdb.OsmAndStructure result = new net.osmand.binary.OsmandOdb.OsmAndStructure(this);
- int from_bitField0_ = bitField0_;
- int to_bitField0_ = 0;
- if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
- to_bitField0_ |= 0x00000001;
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndStructure buildPartial() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "build() has already been called on this Builder.");
}
- result.version_ = version_;
- if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
- to_bitField0_ |= 0x00000002;
+ if (result.addressIndex_ != java.util.Collections.EMPTY_LIST) {
+ result.addressIndex_ =
+ java.util.Collections.unmodifiableList(result.addressIndex_);
}
- result.dateCreated_ = dateCreated_;
- if (addressIndexBuilder_ == null) {
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
- addressIndex_ = java.util.Collections.unmodifiableList(addressIndex_);
- bitField0_ = (bitField0_ & ~0x00000004);
- }
- result.addressIndex_ = addressIndex_;
- } else {
- result.addressIndex_ = addressIndexBuilder_.build();
+ if (result.transportIndex_ != java.util.Collections.EMPTY_LIST) {
+ result.transportIndex_ =
+ java.util.Collections.unmodifiableList(result.transportIndex_);
}
- if (transportIndexBuilder_ == null) {
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
- transportIndex_ = java.util.Collections.unmodifiableList(transportIndex_);
- bitField0_ = (bitField0_ & ~0x00000008);
- }
- result.transportIndex_ = transportIndex_;
- } else {
- result.transportIndex_ = transportIndexBuilder_.build();
+ if (result.poiIndex_ != java.util.Collections.EMPTY_LIST) {
+ result.poiIndex_ =
+ java.util.Collections.unmodifiableList(result.poiIndex_);
}
- if (poiIndexBuilder_ == null) {
- if (((bitField0_ & 0x00000010) == 0x00000010)) {
- poiIndex_ = java.util.Collections.unmodifiableList(poiIndex_);
- bitField0_ = (bitField0_ & ~0x00000010);
- }
- result.poiIndex_ = poiIndex_;
- } else {
- result.poiIndex_ = poiIndexBuilder_.build();
+ if (result.mapIndex_ != java.util.Collections.EMPTY_LIST) {
+ result.mapIndex_ =
+ java.util.Collections.unmodifiableList(result.mapIndex_);
}
- if (mapIndexBuilder_ == null) {
- if (((bitField0_ & 0x00000020) == 0x00000020)) {
- mapIndex_ = java.util.Collections.unmodifiableList(mapIndex_);
- bitField0_ = (bitField0_ & ~0x00000020);
- }
- result.mapIndex_ = mapIndex_;
- } else {
- result.mapIndex_ = mapIndexBuilder_.build();
- }
- if (((from_bitField0_ & 0x00000040) == 0x00000040)) {
- to_bitField0_ |= 0x00000004;
- }
- result.versionConfirm_ = versionConfirm_;
- result.bitField0_ = to_bitField0_;
- onBuilt();
- return result;
+ net.osmand.binary.OsmandOdb.OsmAndStructure returnMe = result;
+ result = null;
+ return returnMe;
}
- public Builder mergeFrom(com.google.protobuf.Message other) {
+ @Override
+ public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof net.osmand.binary.OsmandOdb.OsmAndStructure) {
return mergeFrom((net.osmand.binary.OsmandOdb.OsmAndStructure)other);
} else {
@@ -587,109 +382,29 @@ public final class OsmandOdb {
if (other.hasDateCreated()) {
setDateCreated(other.getDateCreated());
}
- if (addressIndexBuilder_ == null) {
- if (!other.addressIndex_.isEmpty()) {
- if (addressIndex_.isEmpty()) {
- addressIndex_ = other.addressIndex_;
- bitField0_ = (bitField0_ & ~0x00000004);
- } else {
- ensureAddressIndexIsMutable();
- addressIndex_.addAll(other.addressIndex_);
- }
- onChanged();
- }
- } else {
- if (!other.addressIndex_.isEmpty()) {
- if (addressIndexBuilder_.isEmpty()) {
- addressIndexBuilder_.dispose();
- addressIndexBuilder_ = null;
- addressIndex_ = other.addressIndex_;
- bitField0_ = (bitField0_ & ~0x00000004);
- addressIndexBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getAddressIndexFieldBuilder() : null;
- } else {
- addressIndexBuilder_.addAllMessages(other.addressIndex_);
- }
+ if (!other.addressIndex_.isEmpty()) {
+ if (result.addressIndex_.isEmpty()) {
+ result.addressIndex_ = new java.util.ArrayList();
}
+ result.addressIndex_.addAll(other.addressIndex_);
}
- if (transportIndexBuilder_ == null) {
- if (!other.transportIndex_.isEmpty()) {
- if (transportIndex_.isEmpty()) {
- transportIndex_ = other.transportIndex_;
- bitField0_ = (bitField0_ & ~0x00000008);
- } else {
- ensureTransportIndexIsMutable();
- transportIndex_.addAll(other.transportIndex_);
- }
- onChanged();
- }
- } else {
- if (!other.transportIndex_.isEmpty()) {
- if (transportIndexBuilder_.isEmpty()) {
- transportIndexBuilder_.dispose();
- transportIndexBuilder_ = null;
- transportIndex_ = other.transportIndex_;
- bitField0_ = (bitField0_ & ~0x00000008);
- transportIndexBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getTransportIndexFieldBuilder() : null;
- } else {
- transportIndexBuilder_.addAllMessages(other.transportIndex_);
- }
+ if (!other.transportIndex_.isEmpty()) {
+ if (result.transportIndex_.isEmpty()) {
+ result.transportIndex_ = new java.util.ArrayList();
}
+ result.transportIndex_.addAll(other.transportIndex_);
}
- if (poiIndexBuilder_ == null) {
- if (!other.poiIndex_.isEmpty()) {
- if (poiIndex_.isEmpty()) {
- poiIndex_ = other.poiIndex_;
- bitField0_ = (bitField0_ & ~0x00000010);
- } else {
- ensurePoiIndexIsMutable();
- poiIndex_.addAll(other.poiIndex_);
- }
- onChanged();
- }
- } else {
- if (!other.poiIndex_.isEmpty()) {
- if (poiIndexBuilder_.isEmpty()) {
- poiIndexBuilder_.dispose();
- poiIndexBuilder_ = null;
- poiIndex_ = other.poiIndex_;
- bitField0_ = (bitField0_ & ~0x00000010);
- poiIndexBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getPoiIndexFieldBuilder() : null;
- } else {
- poiIndexBuilder_.addAllMessages(other.poiIndex_);
- }
+ if (!other.poiIndex_.isEmpty()) {
+ if (result.poiIndex_.isEmpty()) {
+ result.poiIndex_ = new java.util.ArrayList();
}
+ result.poiIndex_.addAll(other.poiIndex_);
}
- if (mapIndexBuilder_ == null) {
- if (!other.mapIndex_.isEmpty()) {
- if (mapIndex_.isEmpty()) {
- mapIndex_ = other.mapIndex_;
- bitField0_ = (bitField0_ & ~0x00000020);
- } else {
- ensureMapIndexIsMutable();
- mapIndex_.addAll(other.mapIndex_);
- }
- onChanged();
- }
- } else {
- if (!other.mapIndex_.isEmpty()) {
- if (mapIndexBuilder_.isEmpty()) {
- mapIndexBuilder_.dispose();
- mapIndexBuilder_ = null;
- mapIndex_ = other.mapIndex_;
- bitField0_ = (bitField0_ & ~0x00000020);
- mapIndexBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getMapIndexFieldBuilder() : null;
- } else {
- mapIndexBuilder_.addAllMessages(other.mapIndex_);
- }
+ if (!other.mapIndex_.isEmpty()) {
+ if (result.mapIndex_.isEmpty()) {
+ result.mapIndex_ = new java.util.ArrayList();
}
+ result.mapIndex_.addAll(other.mapIndex_);
}
if (other.hasVersionConfirm()) {
setVersionConfirm(other.getVersionConfirm());
@@ -698,47 +413,8 @@ public final class OsmandOdb {
return this;
}
- public final boolean isInitialized() {
- if (!hasVersion()) {
-
- return false;
- }
- if (!hasDateCreated()) {
-
- return false;
- }
- if (!hasVersionConfirm()) {
-
- return false;
- }
- for (int i = 0; i < getAddressIndexCount(); i++) {
- if (!getAddressIndex(i).isInitialized()) {
-
- return false;
- }
- }
- for (int i = 0; i < getTransportIndexCount(); i++) {
- if (!getTransportIndex(i).isInitialized()) {
-
- return false;
- }
- }
- for (int i = 0; i < getPoiIndexCount(); i++) {
- if (!getPoiIndex(i).isInitialized()) {
-
- return false;
- }
- }
- for (int i = 0; i < getMapIndexCount(); i++) {
- if (!getMapIndex(i).isInitialized()) {
-
- return false;
- }
- }
- return true;
- }
-
- public Builder mergeFrom(
+ @Override
+ public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
@@ -750,20 +426,17 @@ public final class OsmandOdb {
switch (tag) {
case 0:
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
default: {
if (!parseUnknownField(input, unknownFields,
extensionRegistry, tag)) {
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
}
break;
}
case 8: {
- bitField0_ |= 0x00000001;
- version_ = input.readUInt32();
+ setVersion(input.readUInt32());
break;
}
case 34: {
@@ -791,825 +464,273 @@ public final class OsmandOdb {
break;
}
case 144: {
- bitField0_ |= 0x00000002;
- dateCreated_ = input.readInt64();
+ setDateCreated(input.readInt64());
break;
}
case 256: {
- bitField0_ |= 0x00000040;
- versionConfirm_ = input.readUInt32();
+ setVersionConfirm(input.readUInt32());
break;
}
}
}
}
- private int bitField0_;
// required uint32 version = 1;
- private int version_ ;
public boolean hasVersion() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
+ return result.hasVersion();
}
public int getVersion() {
- return version_;
+ return result.getVersion();
}
public Builder setVersion(int value) {
- bitField0_ |= 0x00000001;
- version_ = value;
- onChanged();
+ result.hasVersion = true;
+ result.version_ = value;
return this;
}
public Builder clearVersion() {
- bitField0_ = (bitField0_ & ~0x00000001);
- version_ = 0;
- onChanged();
+ result.hasVersion = false;
+ result.version_ = 0;
return this;
}
// required int64 dateCreated = 18;
- private long dateCreated_ ;
public boolean hasDateCreated() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
+ return result.hasDateCreated();
}
public long getDateCreated() {
- return dateCreated_;
+ return result.getDateCreated();
}
public Builder setDateCreated(long value) {
- bitField0_ |= 0x00000002;
- dateCreated_ = value;
- onChanged();
+ result.hasDateCreated = true;
+ result.dateCreated_ = value;
return this;
}
public Builder clearDateCreated() {
- bitField0_ = (bitField0_ & ~0x00000002);
- dateCreated_ = 0L;
- onChanged();
+ result.hasDateCreated = false;
+ result.dateCreated_ = 0L;
return this;
}
// repeated .OsmAndAddressIndex addressIndex = 7;
- private java.util.List addressIndex_ =
- java.util.Collections.emptyList();
- private void ensureAddressIndexIsMutable() {
- if (!((bitField0_ & 0x00000004) == 0x00000004)) {
- addressIndex_ = new java.util.ArrayList(addressIndex_);
- bitField0_ |= 0x00000004;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndAddressIndexOrBuilder> addressIndexBuilder_;
-
public java.util.List getAddressIndexList() {
- if (addressIndexBuilder_ == null) {
- return java.util.Collections.unmodifiableList(addressIndex_);
- } else {
- return addressIndexBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.addressIndex_);
}
public int getAddressIndexCount() {
- if (addressIndexBuilder_ == null) {
- return addressIndex_.size();
- } else {
- return addressIndexBuilder_.getCount();
- }
+ return result.getAddressIndexCount();
}
public net.osmand.binary.OsmandOdb.OsmAndAddressIndex getAddressIndex(int index) {
- if (addressIndexBuilder_ == null) {
- return addressIndex_.get(index);
- } else {
- return addressIndexBuilder_.getMessage(index);
- }
+ return result.getAddressIndex(index);
}
- public Builder setAddressIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndAddressIndex value) {
- if (addressIndexBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureAddressIndexIsMutable();
- addressIndex_.set(index, value);
- onChanged();
- } else {
- addressIndexBuilder_.setMessage(index, value);
+ public Builder setAddressIndex(int index, net.osmand.binary.OsmandOdb.OsmAndAddressIndex value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.addressIndex_.set(index, value);
return this;
}
- public Builder setAddressIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.Builder builderForValue) {
- if (addressIndexBuilder_ == null) {
- ensureAddressIndexIsMutable();
- addressIndex_.set(index, builderForValue.build());
- onChanged();
- } else {
- addressIndexBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setAddressIndex(int index, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.Builder builderForValue) {
+ result.addressIndex_.set(index, builderForValue.build());
return this;
}
public Builder addAddressIndex(net.osmand.binary.OsmandOdb.OsmAndAddressIndex value) {
- if (addressIndexBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureAddressIndexIsMutable();
- addressIndex_.add(value);
- onChanged();
- } else {
- addressIndexBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.addressIndex_.isEmpty()) {
+ result.addressIndex_ = new java.util.ArrayList();
+ }
+ result.addressIndex_.add(value);
return this;
}
- public Builder addAddressIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndAddressIndex value) {
- if (addressIndexBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureAddressIndexIsMutable();
- addressIndex_.add(index, value);
- onChanged();
- } else {
- addressIndexBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addAddressIndex(
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex.Builder builderForValue) {
- if (addressIndexBuilder_ == null) {
- ensureAddressIndexIsMutable();
- addressIndex_.add(builderForValue.build());
- onChanged();
- } else {
- addressIndexBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addAddressIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.Builder builderForValue) {
- if (addressIndexBuilder_ == null) {
- ensureAddressIndexIsMutable();
- addressIndex_.add(index, builderForValue.build());
- onChanged();
- } else {
- addressIndexBuilder_.addMessage(index, builderForValue.build());
+ public Builder addAddressIndex(net.osmand.binary.OsmandOdb.OsmAndAddressIndex.Builder builderForValue) {
+ if (result.addressIndex_.isEmpty()) {
+ result.addressIndex_ = new java.util.ArrayList();
}
+ result.addressIndex_.add(builderForValue.build());
return this;
}
public Builder addAllAddressIndex(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.OsmAndAddressIndex> values) {
- if (addressIndexBuilder_ == null) {
- ensureAddressIndexIsMutable();
- super.addAll(values, addressIndex_);
- onChanged();
- } else {
- addressIndexBuilder_.addAllMessages(values);
+ if (result.addressIndex_.isEmpty()) {
+ result.addressIndex_ = new java.util.ArrayList();
}
+ super.addAll(values, result.addressIndex_);
return this;
}
public Builder clearAddressIndex() {
- if (addressIndexBuilder_ == null) {
- addressIndex_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000004);
- onChanged();
- } else {
- addressIndexBuilder_.clear();
- }
+ result.addressIndex_ = java.util.Collections.emptyList();
return this;
}
- public Builder removeAddressIndex(int index) {
- if (addressIndexBuilder_ == null) {
- ensureAddressIndexIsMutable();
- addressIndex_.remove(index);
- onChanged();
- } else {
- addressIndexBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.Builder getAddressIndexBuilder(
- int index) {
- return getAddressIndexFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndexOrBuilder getAddressIndexOrBuilder(
- int index) {
- if (addressIndexBuilder_ == null) {
- return addressIndex_.get(index); } else {
- return addressIndexBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndAddressIndexOrBuilder>
- getAddressIndexOrBuilderList() {
- if (addressIndexBuilder_ != null) {
- return addressIndexBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(addressIndex_);
- }
- }
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.Builder addAddressIndexBuilder() {
- return getAddressIndexFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.Builder addAddressIndexBuilder(
- int index) {
- return getAddressIndexFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.getDefaultInstance());
- }
- public java.util.List
- getAddressIndexBuilderList() {
- return getAddressIndexFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndAddressIndexOrBuilder>
- getAddressIndexFieldBuilder() {
- if (addressIndexBuilder_ == null) {
- addressIndexBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndAddressIndexOrBuilder>(
- addressIndex_,
- ((bitField0_ & 0x00000004) == 0x00000004),
- getParentForChildren(),
- isClean());
- addressIndex_ = null;
- }
- return addressIndexBuilder_;
- }
// repeated .OsmAndTransportIndex transportIndex = 4;
- private java.util.List transportIndex_ =
- java.util.Collections.emptyList();
- private void ensureTransportIndexIsMutable() {
- if (!((bitField0_ & 0x00000008) == 0x00000008)) {
- transportIndex_ = new java.util.ArrayList(transportIndex_);
- bitField0_ |= 0x00000008;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndTransportIndex, net.osmand.binary.OsmandOdb.OsmAndTransportIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndTransportIndexOrBuilder> transportIndexBuilder_;
-
public java.util.List getTransportIndexList() {
- if (transportIndexBuilder_ == null) {
- return java.util.Collections.unmodifiableList(transportIndex_);
- } else {
- return transportIndexBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.transportIndex_);
}
public int getTransportIndexCount() {
- if (transportIndexBuilder_ == null) {
- return transportIndex_.size();
- } else {
- return transportIndexBuilder_.getCount();
- }
+ return result.getTransportIndexCount();
}
public net.osmand.binary.OsmandOdb.OsmAndTransportIndex getTransportIndex(int index) {
- if (transportIndexBuilder_ == null) {
- return transportIndex_.get(index);
- } else {
- return transportIndexBuilder_.getMessage(index);
- }
+ return result.getTransportIndex(index);
}
- public Builder setTransportIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndTransportIndex value) {
- if (transportIndexBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureTransportIndexIsMutable();
- transportIndex_.set(index, value);
- onChanged();
- } else {
- transportIndexBuilder_.setMessage(index, value);
+ public Builder setTransportIndex(int index, net.osmand.binary.OsmandOdb.OsmAndTransportIndex value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.transportIndex_.set(index, value);
return this;
}
- public Builder setTransportIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndTransportIndex.Builder builderForValue) {
- if (transportIndexBuilder_ == null) {
- ensureTransportIndexIsMutable();
- transportIndex_.set(index, builderForValue.build());
- onChanged();
- } else {
- transportIndexBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setTransportIndex(int index, net.osmand.binary.OsmandOdb.OsmAndTransportIndex.Builder builderForValue) {
+ result.transportIndex_.set(index, builderForValue.build());
return this;
}
public Builder addTransportIndex(net.osmand.binary.OsmandOdb.OsmAndTransportIndex value) {
- if (transportIndexBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureTransportIndexIsMutable();
- transportIndex_.add(value);
- onChanged();
- } else {
- transportIndexBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.transportIndex_.isEmpty()) {
+ result.transportIndex_ = new java.util.ArrayList();
+ }
+ result.transportIndex_.add(value);
return this;
}
- public Builder addTransportIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndTransportIndex value) {
- if (transportIndexBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureTransportIndexIsMutable();
- transportIndex_.add(index, value);
- onChanged();
- } else {
- transportIndexBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addTransportIndex(
- net.osmand.binary.OsmandOdb.OsmAndTransportIndex.Builder builderForValue) {
- if (transportIndexBuilder_ == null) {
- ensureTransportIndexIsMutable();
- transportIndex_.add(builderForValue.build());
- onChanged();
- } else {
- transportIndexBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addTransportIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndTransportIndex.Builder builderForValue) {
- if (transportIndexBuilder_ == null) {
- ensureTransportIndexIsMutable();
- transportIndex_.add(index, builderForValue.build());
- onChanged();
- } else {
- transportIndexBuilder_.addMessage(index, builderForValue.build());
+ public Builder addTransportIndex(net.osmand.binary.OsmandOdb.OsmAndTransportIndex.Builder builderForValue) {
+ if (result.transportIndex_.isEmpty()) {
+ result.transportIndex_ = new java.util.ArrayList();
}
+ result.transportIndex_.add(builderForValue.build());
return this;
}
public Builder addAllTransportIndex(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.OsmAndTransportIndex> values) {
- if (transportIndexBuilder_ == null) {
- ensureTransportIndexIsMutable();
- super.addAll(values, transportIndex_);
- onChanged();
- } else {
- transportIndexBuilder_.addAllMessages(values);
+ if (result.transportIndex_.isEmpty()) {
+ result.transportIndex_ = new java.util.ArrayList();
}
+ super.addAll(values, result.transportIndex_);
return this;
}
public Builder clearTransportIndex() {
- if (transportIndexBuilder_ == null) {
- transportIndex_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000008);
- onChanged();
- } else {
- transportIndexBuilder_.clear();
- }
+ result.transportIndex_ = java.util.Collections.emptyList();
return this;
}
- public Builder removeTransportIndex(int index) {
- if (transportIndexBuilder_ == null) {
- ensureTransportIndexIsMutable();
- transportIndex_.remove(index);
- onChanged();
- } else {
- transportIndexBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.OsmAndTransportIndex.Builder getTransportIndexBuilder(
- int index) {
- return getTransportIndexFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.OsmAndTransportIndexOrBuilder getTransportIndexOrBuilder(
- int index) {
- if (transportIndexBuilder_ == null) {
- return transportIndex_.get(index); } else {
- return transportIndexBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndTransportIndexOrBuilder>
- getTransportIndexOrBuilderList() {
- if (transportIndexBuilder_ != null) {
- return transportIndexBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(transportIndex_);
- }
- }
- public net.osmand.binary.OsmandOdb.OsmAndTransportIndex.Builder addTransportIndexBuilder() {
- return getTransportIndexFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.OsmAndTransportIndex.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.OsmAndTransportIndex.Builder addTransportIndexBuilder(
- int index) {
- return getTransportIndexFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.OsmAndTransportIndex.getDefaultInstance());
- }
- public java.util.List
- getTransportIndexBuilderList() {
- return getTransportIndexFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndTransportIndex, net.osmand.binary.OsmandOdb.OsmAndTransportIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndTransportIndexOrBuilder>
- getTransportIndexFieldBuilder() {
- if (transportIndexBuilder_ == null) {
- transportIndexBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndTransportIndex, net.osmand.binary.OsmandOdb.OsmAndTransportIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndTransportIndexOrBuilder>(
- transportIndex_,
- ((bitField0_ & 0x00000008) == 0x00000008),
- getParentForChildren(),
- isClean());
- transportIndex_ = null;
- }
- return transportIndexBuilder_;
- }
// repeated .OsmAndPoiIndex poiIndex = 8;
- private java.util.List poiIndex_ =
- java.util.Collections.emptyList();
- private void ensurePoiIndexIsMutable() {
- if (!((bitField0_ & 0x00000010) == 0x00000010)) {
- poiIndex_ = new java.util.ArrayList(poiIndex_);
- bitField0_ |= 0x00000010;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndPoiIndex, net.osmand.binary.OsmandOdb.OsmAndPoiIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndPoiIndexOrBuilder> poiIndexBuilder_;
-
public java.util.List getPoiIndexList() {
- if (poiIndexBuilder_ == null) {
- return java.util.Collections.unmodifiableList(poiIndex_);
- } else {
- return poiIndexBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.poiIndex_);
}
public int getPoiIndexCount() {
- if (poiIndexBuilder_ == null) {
- return poiIndex_.size();
- } else {
- return poiIndexBuilder_.getCount();
- }
+ return result.getPoiIndexCount();
}
public net.osmand.binary.OsmandOdb.OsmAndPoiIndex getPoiIndex(int index) {
- if (poiIndexBuilder_ == null) {
- return poiIndex_.get(index);
- } else {
- return poiIndexBuilder_.getMessage(index);
- }
+ return result.getPoiIndex(index);
}
- public Builder setPoiIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndPoiIndex value) {
- if (poiIndexBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensurePoiIndexIsMutable();
- poiIndex_.set(index, value);
- onChanged();
- } else {
- poiIndexBuilder_.setMessage(index, value);
+ public Builder setPoiIndex(int index, net.osmand.binary.OsmandOdb.OsmAndPoiIndex value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.poiIndex_.set(index, value);
return this;
}
- public Builder setPoiIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndPoiIndex.Builder builderForValue) {
- if (poiIndexBuilder_ == null) {
- ensurePoiIndexIsMutable();
- poiIndex_.set(index, builderForValue.build());
- onChanged();
- } else {
- poiIndexBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setPoiIndex(int index, net.osmand.binary.OsmandOdb.OsmAndPoiIndex.Builder builderForValue) {
+ result.poiIndex_.set(index, builderForValue.build());
return this;
}
public Builder addPoiIndex(net.osmand.binary.OsmandOdb.OsmAndPoiIndex value) {
- if (poiIndexBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensurePoiIndexIsMutable();
- poiIndex_.add(value);
- onChanged();
- } else {
- poiIndexBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.poiIndex_.isEmpty()) {
+ result.poiIndex_ = new java.util.ArrayList();
+ }
+ result.poiIndex_.add(value);
return this;
}
- public Builder addPoiIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndPoiIndex value) {
- if (poiIndexBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensurePoiIndexIsMutable();
- poiIndex_.add(index, value);
- onChanged();
- } else {
- poiIndexBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addPoiIndex(
- net.osmand.binary.OsmandOdb.OsmAndPoiIndex.Builder builderForValue) {
- if (poiIndexBuilder_ == null) {
- ensurePoiIndexIsMutable();
- poiIndex_.add(builderForValue.build());
- onChanged();
- } else {
- poiIndexBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addPoiIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndPoiIndex.Builder builderForValue) {
- if (poiIndexBuilder_ == null) {
- ensurePoiIndexIsMutable();
- poiIndex_.add(index, builderForValue.build());
- onChanged();
- } else {
- poiIndexBuilder_.addMessage(index, builderForValue.build());
+ public Builder addPoiIndex(net.osmand.binary.OsmandOdb.OsmAndPoiIndex.Builder builderForValue) {
+ if (result.poiIndex_.isEmpty()) {
+ result.poiIndex_ = new java.util.ArrayList();
}
+ result.poiIndex_.add(builderForValue.build());
return this;
}
public Builder addAllPoiIndex(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.OsmAndPoiIndex> values) {
- if (poiIndexBuilder_ == null) {
- ensurePoiIndexIsMutable();
- super.addAll(values, poiIndex_);
- onChanged();
- } else {
- poiIndexBuilder_.addAllMessages(values);
+ if (result.poiIndex_.isEmpty()) {
+ result.poiIndex_ = new java.util.ArrayList();
}
+ super.addAll(values, result.poiIndex_);
return this;
}
public Builder clearPoiIndex() {
- if (poiIndexBuilder_ == null) {
- poiIndex_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000010);
- onChanged();
- } else {
- poiIndexBuilder_.clear();
- }
+ result.poiIndex_ = java.util.Collections.emptyList();
return this;
}
- public Builder removePoiIndex(int index) {
- if (poiIndexBuilder_ == null) {
- ensurePoiIndexIsMutable();
- poiIndex_.remove(index);
- onChanged();
- } else {
- poiIndexBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.OsmAndPoiIndex.Builder getPoiIndexBuilder(
- int index) {
- return getPoiIndexFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.OsmAndPoiIndexOrBuilder getPoiIndexOrBuilder(
- int index) {
- if (poiIndexBuilder_ == null) {
- return poiIndex_.get(index); } else {
- return poiIndexBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndPoiIndexOrBuilder>
- getPoiIndexOrBuilderList() {
- if (poiIndexBuilder_ != null) {
- return poiIndexBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(poiIndex_);
- }
- }
- public net.osmand.binary.OsmandOdb.OsmAndPoiIndex.Builder addPoiIndexBuilder() {
- return getPoiIndexFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.OsmAndPoiIndex.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.OsmAndPoiIndex.Builder addPoiIndexBuilder(
- int index) {
- return getPoiIndexFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.OsmAndPoiIndex.getDefaultInstance());
- }
- public java.util.List
- getPoiIndexBuilderList() {
- return getPoiIndexFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndPoiIndex, net.osmand.binary.OsmandOdb.OsmAndPoiIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndPoiIndexOrBuilder>
- getPoiIndexFieldBuilder() {
- if (poiIndexBuilder_ == null) {
- poiIndexBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndPoiIndex, net.osmand.binary.OsmandOdb.OsmAndPoiIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndPoiIndexOrBuilder>(
- poiIndex_,
- ((bitField0_ & 0x00000010) == 0x00000010),
- getParentForChildren(),
- isClean());
- poiIndex_ = null;
- }
- return poiIndexBuilder_;
- }
// repeated .OsmAndMapIndex mapIndex = 6;
- private java.util.List mapIndex_ =
- java.util.Collections.emptyList();
- private void ensureMapIndexIsMutable() {
- if (!((bitField0_ & 0x00000020) == 0x00000020)) {
- mapIndex_ = new java.util.ArrayList(mapIndex_);
- bitField0_ |= 0x00000020;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex, net.osmand.binary.OsmandOdb.OsmAndMapIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndexOrBuilder> mapIndexBuilder_;
-
public java.util.List getMapIndexList() {
- if (mapIndexBuilder_ == null) {
- return java.util.Collections.unmodifiableList(mapIndex_);
- } else {
- return mapIndexBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.mapIndex_);
}
public int getMapIndexCount() {
- if (mapIndexBuilder_ == null) {
- return mapIndex_.size();
- } else {
- return mapIndexBuilder_.getCount();
- }
+ return result.getMapIndexCount();
}
public net.osmand.binary.OsmandOdb.OsmAndMapIndex getMapIndex(int index) {
- if (mapIndexBuilder_ == null) {
- return mapIndex_.get(index);
- } else {
- return mapIndexBuilder_.getMessage(index);
- }
+ return result.getMapIndex(index);
}
- public Builder setMapIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex value) {
- if (mapIndexBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureMapIndexIsMutable();
- mapIndex_.set(index, value);
- onChanged();
- } else {
- mapIndexBuilder_.setMessage(index, value);
+ public Builder setMapIndex(int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.mapIndex_.set(index, value);
return this;
}
- public Builder setMapIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.Builder builderForValue) {
- if (mapIndexBuilder_ == null) {
- ensureMapIndexIsMutable();
- mapIndex_.set(index, builderForValue.build());
- onChanged();
- } else {
- mapIndexBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setMapIndex(int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.Builder builderForValue) {
+ result.mapIndex_.set(index, builderForValue.build());
return this;
}
public Builder addMapIndex(net.osmand.binary.OsmandOdb.OsmAndMapIndex value) {
- if (mapIndexBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureMapIndexIsMutable();
- mapIndex_.add(value);
- onChanged();
- } else {
- mapIndexBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.mapIndex_.isEmpty()) {
+ result.mapIndex_ = new java.util.ArrayList();
+ }
+ result.mapIndex_.add(value);
return this;
}
- public Builder addMapIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex value) {
- if (mapIndexBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureMapIndexIsMutable();
- mapIndex_.add(index, value);
- onChanged();
- } else {
- mapIndexBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addMapIndex(
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.Builder builderForValue) {
- if (mapIndexBuilder_ == null) {
- ensureMapIndexIsMutable();
- mapIndex_.add(builderForValue.build());
- onChanged();
- } else {
- mapIndexBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addMapIndex(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.Builder builderForValue) {
- if (mapIndexBuilder_ == null) {
- ensureMapIndexIsMutable();
- mapIndex_.add(index, builderForValue.build());
- onChanged();
- } else {
- mapIndexBuilder_.addMessage(index, builderForValue.build());
+ public Builder addMapIndex(net.osmand.binary.OsmandOdb.OsmAndMapIndex.Builder builderForValue) {
+ if (result.mapIndex_.isEmpty()) {
+ result.mapIndex_ = new java.util.ArrayList();
}
+ result.mapIndex_.add(builderForValue.build());
return this;
}
public Builder addAllMapIndex(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.OsmAndMapIndex> values) {
- if (mapIndexBuilder_ == null) {
- ensureMapIndexIsMutable();
- super.addAll(values, mapIndex_);
- onChanged();
- } else {
- mapIndexBuilder_.addAllMessages(values);
+ if (result.mapIndex_.isEmpty()) {
+ result.mapIndex_ = new java.util.ArrayList();
}
+ super.addAll(values, result.mapIndex_);
return this;
}
public Builder clearMapIndex() {
- if (mapIndexBuilder_ == null) {
- mapIndex_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000020);
- onChanged();
- } else {
- mapIndexBuilder_.clear();
- }
+ result.mapIndex_ = java.util.Collections.emptyList();
return this;
}
- public Builder removeMapIndex(int index) {
- if (mapIndexBuilder_ == null) {
- ensureMapIndexIsMutable();
- mapIndex_.remove(index);
- onChanged();
- } else {
- mapIndexBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.Builder getMapIndexBuilder(
- int index) {
- return getMapIndexFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndexOrBuilder getMapIndexOrBuilder(
- int index) {
- if (mapIndexBuilder_ == null) {
- return mapIndex_.get(index); } else {
- return mapIndexBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndexOrBuilder>
- getMapIndexOrBuilderList() {
- if (mapIndexBuilder_ != null) {
- return mapIndexBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(mapIndex_);
- }
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.Builder addMapIndexBuilder() {
- return getMapIndexFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.Builder addMapIndexBuilder(
- int index) {
- return getMapIndexFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.getDefaultInstance());
- }
- public java.util.List
- getMapIndexBuilderList() {
- return getMapIndexFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex, net.osmand.binary.OsmandOdb.OsmAndMapIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndexOrBuilder>
- getMapIndexFieldBuilder() {
- if (mapIndexBuilder_ == null) {
- mapIndexBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex, net.osmand.binary.OsmandOdb.OsmAndMapIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndexOrBuilder>(
- mapIndex_,
- ((bitField0_ & 0x00000020) == 0x00000020),
- getParentForChildren(),
- isClean());
- mapIndex_ = null;
- }
- return mapIndexBuilder_;
- }
// required uint32 versionConfirm = 32;
- private int versionConfirm_ ;
public boolean hasVersionConfirm() {
- return ((bitField0_ & 0x00000040) == 0x00000040);
+ return result.hasVersionConfirm();
}
public int getVersionConfirm() {
- return versionConfirm_;
+ return result.getVersionConfirm();
}
public Builder setVersionConfirm(int value) {
- bitField0_ |= 0x00000040;
- versionConfirm_ = value;
- onChanged();
+ result.hasVersionConfirm = true;
+ result.versionConfirm_ = value;
return this;
}
public Builder clearVersionConfirm() {
- bitField0_ = (bitField0_ & ~0x00000040);
- versionConfirm_ = 0;
- onChanged();
+ result.hasVersionConfirm = false;
+ result.versionConfirm_ = 0;
return this;
}
@@ -1618,37 +739,18 @@ public final class OsmandOdb {
static {
defaultInstance = new OsmAndStructure(true);
+ net.osmand.binary.OsmandOdb.internalForceInit();
defaultInstance.initFields();
}
// @@protoc_insertion_point(class_scope:OsmAndStructure)
}
- public interface OsmAndTileBoxOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // required uint32 left = 1;
- boolean hasLeft();
- int getLeft();
-
- // required uint32 right = 2;
- boolean hasRight();
- int getRight();
-
- // required uint32 top = 3;
- boolean hasTop();
- int getTop();
-
- // required uint32 bottom = 4;
- boolean hasBottom();
- int getBottom();
- }
public static final class OsmAndTileBox extends
- com.google.protobuf.GeneratedMessage
- implements OsmAndTileBoxOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use OsmAndTileBox.newBuilder() to construct.
- private OsmAndTileBox(Builder builder) {
- super(builder);
+ private OsmAndTileBox() {
+ initFields();
}
private OsmAndTileBox(boolean noInit) {}
@@ -1657,7 +759,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public OsmAndTileBox getDefaultInstanceForType() {
+ @Override
+ public OsmAndTileBox getDefaultInstanceForType() {
return defaultInstance;
}
@@ -1666,135 +769,98 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndTileBox_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndTileBox_fieldAccessorTable;
}
- private int bitField0_;
// required uint32 left = 1;
public static final int LEFT_FIELD_NUMBER = 1;
- private int left_;
- public boolean hasLeft() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
- }
- public int getLeft() {
- return left_;
- }
+ private boolean hasLeft;
+ private int left_ = 0;
+ public boolean hasLeft() { return hasLeft; }
+ public int getLeft() { return left_; }
// required uint32 right = 2;
public static final int RIGHT_FIELD_NUMBER = 2;
- private int right_;
- public boolean hasRight() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
- }
- public int getRight() {
- return right_;
- }
+ private boolean hasRight;
+ private int right_ = 0;
+ public boolean hasRight() { return hasRight; }
+ public int getRight() { return right_; }
// required uint32 top = 3;
public static final int TOP_FIELD_NUMBER = 3;
- private int top_;
- public boolean hasTop() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
- }
- public int getTop() {
- return top_;
- }
+ private boolean hasTop;
+ private int top_ = 0;
+ public boolean hasTop() { return hasTop; }
+ public int getTop() { return top_; }
// required uint32 bottom = 4;
public static final int BOTTOM_FIELD_NUMBER = 4;
- private int bottom_;
- public boolean hasBottom() {
- return ((bitField0_ & 0x00000008) == 0x00000008);
- }
- public int getBottom() {
- return bottom_;
- }
+ private boolean hasBottom;
+ private int bottom_ = 0;
+ public boolean hasBottom() { return hasBottom; }
+ public int getBottom() { return bottom_; }
private void initFields() {
- left_ = 0;
- right_ = 0;
- top_ = 0;
- bottom_ = 0;
}
- private byte memoizedIsInitialized = -1;
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized != -1) return isInitialized == 1;
-
- if (!hasLeft()) {
- memoizedIsInitialized = 0;
- return false;
- }
- if (!hasRight()) {
- memoizedIsInitialized = 0;
- return false;
- }
- if (!hasTop()) {
- memoizedIsInitialized = 0;
- return false;
- }
- if (!hasBottom()) {
- memoizedIsInitialized = 0;
- return false;
- }
- memoizedIsInitialized = 1;
+ @Override
+ public final boolean isInitialized() {
+ if (!hasLeft) return false;
+ if (!hasRight) return false;
+ if (!hasTop) return false;
+ if (!hasBottom) return false;
return true;
}
- public void writeTo(com.google.protobuf.CodedOutputStream output)
+ @Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
- output.writeUInt32(1, left_);
+ if (hasLeft()) {
+ output.writeUInt32(1, getLeft());
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
- output.writeUInt32(2, right_);
+ if (hasRight()) {
+ output.writeUInt32(2, getRight());
}
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
- output.writeUInt32(3, top_);
+ if (hasTop()) {
+ output.writeUInt32(3, getTop());
}
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
- output.writeUInt32(4, bottom_);
+ if (hasBottom()) {
+ output.writeUInt32(4, getBottom());
}
getUnknownFields().writeTo(output);
}
private int memoizedSerializedSize = -1;
- public int getSerializedSize() {
+ @Override
+ public int getSerializedSize() {
int size = memoizedSerializedSize;
if (size != -1) return size;
size = 0;
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ if (hasLeft()) {
size += com.google.protobuf.CodedOutputStream
- .computeUInt32Size(1, left_);
+ .computeUInt32Size(1, getLeft());
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
+ if (hasRight()) {
size += com.google.protobuf.CodedOutputStream
- .computeUInt32Size(2, right_);
+ .computeUInt32Size(2, getRight());
}
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
+ if (hasTop()) {
size += com.google.protobuf.CodedOutputStream
- .computeUInt32Size(3, top_);
+ .computeUInt32Size(3, getTop());
}
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
+ if (hasBottom()) {
size += com.google.protobuf.CodedOutputStream
- .computeUInt32Size(4, bottom_);
+ .computeUInt32Size(4, getBottom());
}
size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size;
return size;
}
- private static final long serialVersionUID = 0L;
- @java.lang.Override
- protected java.lang.Object writeReplace()
- throws java.io.ObjectStreamException {
- return super.writeReplace();
- }
-
public static net.osmand.binary.OsmandOdb.OsmAndTileBox parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
@@ -1863,118 +929,92 @@ public final class OsmandOdb {
}
public static Builder newBuilder() { return Builder.create(); }
- public Builder newBuilderForType() { return newBuilder(); }
+ @Override
+ public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder(net.osmand.binary.OsmandOdb.OsmAndTileBox prototype) {
return newBuilder().mergeFrom(prototype);
}
- public Builder toBuilder() { return newBuilder(this); }
+ @Override
+ public Builder toBuilder() { return newBuilder(this); }
- @java.lang.Override
- protected Builder newBuilderForType(
- com.google.protobuf.GeneratedMessage.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
public static final class Builder extends
- com.google.protobuf.GeneratedMessage.Builder
- implements net.osmand.binary.OsmandOdb.OsmAndTileBoxOrBuilder {
- public static final com.google.protobuf.Descriptors.Descriptor
- getDescriptor() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndTileBox_descriptor;
- }
-
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
- internalGetFieldAccessorTable() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndTileBox_fieldAccessorTable;
- }
+ com.google.protobuf.GeneratedMessage.Builder {
+ private net.osmand.binary.OsmandOdb.OsmAndTileBox result;
// Construct using net.osmand.binary.OsmandOdb.OsmAndTileBox.newBuilder()
- private Builder() {
- maybeForceBuilderInitialization();
- }
+ private Builder() {}
- private Builder(BuilderParent parent) {
- super(parent);
- maybeForceBuilderInitialization();
- }
- private void maybeForceBuilderInitialization() {
- if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
- }
- }
private static Builder create() {
- return new Builder();
+ Builder builder = new Builder();
+ builder.result = new net.osmand.binary.OsmandOdb.OsmAndTileBox();
+ return builder;
}
- public Builder clear() {
- super.clear();
- left_ = 0;
- bitField0_ = (bitField0_ & ~0x00000001);
- right_ = 0;
- bitField0_ = (bitField0_ & ~0x00000002);
- top_ = 0;
- bitField0_ = (bitField0_ & ~0x00000004);
- bottom_ = 0;
- bitField0_ = (bitField0_ & ~0x00000008);
+ @Override
+ protected net.osmand.binary.OsmandOdb.OsmAndTileBox internalGetResult() {
+ return result;
+ }
+
+ @Override
+ public Builder clear() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "Cannot call clear() after build().");
+ }
+ result = new net.osmand.binary.OsmandOdb.OsmAndTileBox();
return this;
}
- public Builder clone() {
- return create().mergeFrom(buildPartial());
+ @Override
+ public Builder clone() {
+ return create().mergeFrom(result);
}
- public com.google.protobuf.Descriptors.Descriptor
+ @Override
+ public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return net.osmand.binary.OsmandOdb.OsmAndTileBox.getDescriptor();
}
- public net.osmand.binary.OsmandOdb.OsmAndTileBox getDefaultInstanceForType() {
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndTileBox getDefaultInstanceForType() {
return net.osmand.binary.OsmandOdb.OsmAndTileBox.getDefaultInstance();
}
- public net.osmand.binary.OsmandOdb.OsmAndTileBox build() {
- net.osmand.binary.OsmandOdb.OsmAndTileBox result = buildPartial();
- if (!result.isInitialized()) {
+ @Override
+ public boolean isInitialized() {
+ return result.isInitialized();
+ }
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndTileBox build() {
+ if (result != null && !isInitialized()) {
throw newUninitializedMessageException(result);
}
- return result;
+ return buildPartial();
}
private net.osmand.binary.OsmandOdb.OsmAndTileBox buildParsed()
throws com.google.protobuf.InvalidProtocolBufferException {
- net.osmand.binary.OsmandOdb.OsmAndTileBox result = buildPartial();
- if (!result.isInitialized()) {
+ if (!isInitialized()) {
throw newUninitializedMessageException(
result).asInvalidProtocolBufferException();
}
- return result;
+ return buildPartial();
}
- public net.osmand.binary.OsmandOdb.OsmAndTileBox buildPartial() {
- net.osmand.binary.OsmandOdb.OsmAndTileBox result = new net.osmand.binary.OsmandOdb.OsmAndTileBox(this);
- int from_bitField0_ = bitField0_;
- int to_bitField0_ = 0;
- if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
- to_bitField0_ |= 0x00000001;
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndTileBox buildPartial() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "build() has already been called on this Builder.");
}
- result.left_ = left_;
- if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
- to_bitField0_ |= 0x00000002;
- }
- result.right_ = right_;
- if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
- to_bitField0_ |= 0x00000004;
- }
- result.top_ = top_;
- if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
- to_bitField0_ |= 0x00000008;
- }
- result.bottom_ = bottom_;
- result.bitField0_ = to_bitField0_;
- onBuilt();
- return result;
+ net.osmand.binary.OsmandOdb.OsmAndTileBox returnMe = result;
+ result = null;
+ return returnMe;
}
- public Builder mergeFrom(com.google.protobuf.Message other) {
+ @Override
+ public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof net.osmand.binary.OsmandOdb.OsmAndTileBox) {
return mergeFrom((net.osmand.binary.OsmandOdb.OsmAndTileBox)other);
} else {
@@ -2001,27 +1041,8 @@ public final class OsmandOdb {
return this;
}
- public final boolean isInitialized() {
- if (!hasLeft()) {
-
- return false;
- }
- if (!hasRight()) {
-
- return false;
- }
- if (!hasTop()) {
-
- return false;
- }
- if (!hasBottom()) {
-
- return false;
- }
- return true;
- }
-
- public Builder mergeFrom(
+ @Override
+ public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
@@ -2033,124 +1054,105 @@ public final class OsmandOdb {
switch (tag) {
case 0:
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
default: {
if (!parseUnknownField(input, unknownFields,
extensionRegistry, tag)) {
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
}
break;
}
case 8: {
- bitField0_ |= 0x00000001;
- left_ = input.readUInt32();
+ setLeft(input.readUInt32());
break;
}
case 16: {
- bitField0_ |= 0x00000002;
- right_ = input.readUInt32();
+ setRight(input.readUInt32());
break;
}
case 24: {
- bitField0_ |= 0x00000004;
- top_ = input.readUInt32();
+ setTop(input.readUInt32());
break;
}
case 32: {
- bitField0_ |= 0x00000008;
- bottom_ = input.readUInt32();
+ setBottom(input.readUInt32());
break;
}
}
}
}
- private int bitField0_;
// required uint32 left = 1;
- private int left_ ;
public boolean hasLeft() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
+ return result.hasLeft();
}
public int getLeft() {
- return left_;
+ return result.getLeft();
}
public Builder setLeft(int value) {
- bitField0_ |= 0x00000001;
- left_ = value;
- onChanged();
+ result.hasLeft = true;
+ result.left_ = value;
return this;
}
public Builder clearLeft() {
- bitField0_ = (bitField0_ & ~0x00000001);
- left_ = 0;
- onChanged();
+ result.hasLeft = false;
+ result.left_ = 0;
return this;
}
// required uint32 right = 2;
- private int right_ ;
public boolean hasRight() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
+ return result.hasRight();
}
public int getRight() {
- return right_;
+ return result.getRight();
}
public Builder setRight(int value) {
- bitField0_ |= 0x00000002;
- right_ = value;
- onChanged();
+ result.hasRight = true;
+ result.right_ = value;
return this;
}
public Builder clearRight() {
- bitField0_ = (bitField0_ & ~0x00000002);
- right_ = 0;
- onChanged();
+ result.hasRight = false;
+ result.right_ = 0;
return this;
}
// required uint32 top = 3;
- private int top_ ;
public boolean hasTop() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
+ return result.hasTop();
}
public int getTop() {
- return top_;
+ return result.getTop();
}
public Builder setTop(int value) {
- bitField0_ |= 0x00000004;
- top_ = value;
- onChanged();
+ result.hasTop = true;
+ result.top_ = value;
return this;
}
public Builder clearTop() {
- bitField0_ = (bitField0_ & ~0x00000004);
- top_ = 0;
- onChanged();
+ result.hasTop = false;
+ result.top_ = 0;
return this;
}
// required uint32 bottom = 4;
- private int bottom_ ;
public boolean hasBottom() {
- return ((bitField0_ & 0x00000008) == 0x00000008);
+ return result.hasBottom();
}
public int getBottom() {
- return bottom_;
+ return result.getBottom();
}
public Builder setBottom(int value) {
- bitField0_ |= 0x00000008;
- bottom_ = value;
- onChanged();
+ result.hasBottom = true;
+ result.bottom_ = value;
return this;
}
public Builder clearBottom() {
- bitField0_ = (bitField0_ & ~0x00000008);
- bottom_ = 0;
- onChanged();
+ result.hasBottom = false;
+ result.bottom_ = 0;
return this;
}
@@ -2159,26 +1161,18 @@ public final class OsmandOdb {
static {
defaultInstance = new OsmAndTileBox(true);
+ net.osmand.binary.OsmandOdb.internalForceInit();
defaultInstance.initFields();
}
// @@protoc_insertion_point(class_scope:OsmAndTileBox)
}
- public interface StringTableOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // repeated string s = 1;
- java.util.List getSList();
- int getSCount();
- String getS(int index);
- }
public static final class StringTable extends
- com.google.protobuf.GeneratedMessage
- implements StringTableOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use StringTable.newBuilder() to construct.
- private StringTable(Builder builder) {
- super(builder);
+ private StringTable() {
+ initFields();
}
private StringTable(boolean noInit) {}
@@ -2187,7 +1181,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public StringTable getDefaultInstanceForType() {
+ @Override
+ public StringTable getDefaultInstanceForType() {
return defaultInstance;
}
@@ -2196,57 +1191,53 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_StringTable_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_StringTable_fieldAccessorTable;
}
// repeated string s = 1;
public static final int S_FIELD_NUMBER = 1;
- private com.google.protobuf.LazyStringList s_;
- public java.util.List
- getSList() {
+ private java.util.List s_ =
+ java.util.Collections.emptyList();
+ public java.util.List getSList() {
return s_;
}
- public int getSCount() {
- return s_.size();
- }
- public String getS(int index) {
+ public int getSCount() { return s_.size(); }
+ public java.lang.String getS(int index) {
return s_.get(index);
}
private void initFields() {
- s_ = com.google.protobuf.LazyStringArrayList.EMPTY;
}
- private byte memoizedIsInitialized = -1;
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized != -1) return isInitialized == 1;
-
- memoizedIsInitialized = 1;
+ @Override
+ public final boolean isInitialized() {
return true;
}
- public void writeTo(com.google.protobuf.CodedOutputStream output)
+ @Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
- for (int i = 0; i < s_.size(); i++) {
- output.writeBytes(1, s_.getByteString(i));
+ for (java.lang.String element : getSList()) {
+ output.writeString(1, element);
}
getUnknownFields().writeTo(output);
}
private int memoizedSerializedSize = -1;
- public int getSerializedSize() {
+ @Override
+ public int getSerializedSize() {
int size = memoizedSerializedSize;
if (size != -1) return size;
size = 0;
{
int dataSize = 0;
- for (int i = 0; i < s_.size(); i++) {
+ for (java.lang.String element : getSList()) {
dataSize += com.google.protobuf.CodedOutputStream
- .computeBytesSizeNoTag(s_.getByteString(i));
+ .computeStringSizeNoTag(element);
}
size += dataSize;
size += 1 * getSList().size();
@@ -2256,13 +1247,6 @@ public final class OsmandOdb {
return size;
}
- private static final long serialVersionUID = 0L;
- @java.lang.Override
- protected java.lang.Object writeReplace()
- throws java.io.ObjectStreamException {
- return super.writeReplace();
- }
-
public static net.osmand.binary.OsmandOdb.StringTable parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
@@ -2331,100 +1315,96 @@ public final class OsmandOdb {
}
public static Builder newBuilder() { return Builder.create(); }
- public Builder newBuilderForType() { return newBuilder(); }
+ @Override
+ public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder(net.osmand.binary.OsmandOdb.StringTable prototype) {
return newBuilder().mergeFrom(prototype);
}
- public Builder toBuilder() { return newBuilder(this); }
+ @Override
+ public Builder toBuilder() { return newBuilder(this); }
- @java.lang.Override
- protected Builder newBuilderForType(
- com.google.protobuf.GeneratedMessage.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
public static final class Builder extends
- com.google.protobuf.GeneratedMessage.Builder
- implements net.osmand.binary.OsmandOdb.StringTableOrBuilder {
- public static final com.google.protobuf.Descriptors.Descriptor
- getDescriptor() {
- return net.osmand.binary.OsmandOdb.internal_static_StringTable_descriptor;
- }
-
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
- internalGetFieldAccessorTable() {
- return net.osmand.binary.OsmandOdb.internal_static_StringTable_fieldAccessorTable;
- }
+ com.google.protobuf.GeneratedMessage.Builder {
+ private net.osmand.binary.OsmandOdb.StringTable result;
// Construct using net.osmand.binary.OsmandOdb.StringTable.newBuilder()
- private Builder() {
- maybeForceBuilderInitialization();
- }
+ private Builder() {}
- private Builder(BuilderParent parent) {
- super(parent);
- maybeForceBuilderInitialization();
- }
- private void maybeForceBuilderInitialization() {
- if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
- }
- }
private static Builder create() {
- return new Builder();
+ Builder builder = new Builder();
+ builder.result = new net.osmand.binary.OsmandOdb.StringTable();
+ return builder;
}
- public Builder clear() {
- super.clear();
- s_ = com.google.protobuf.LazyStringArrayList.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000001);
+ @Override
+ protected net.osmand.binary.OsmandOdb.StringTable internalGetResult() {
+ return result;
+ }
+
+ @Override
+ public Builder clear() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "Cannot call clear() after build().");
+ }
+ result = new net.osmand.binary.OsmandOdb.StringTable();
return this;
}
- public Builder clone() {
- return create().mergeFrom(buildPartial());
+ @Override
+ public Builder clone() {
+ return create().mergeFrom(result);
}
- public com.google.protobuf.Descriptors.Descriptor
+ @Override
+ public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return net.osmand.binary.OsmandOdb.StringTable.getDescriptor();
}
- public net.osmand.binary.OsmandOdb.StringTable getDefaultInstanceForType() {
+ @Override
+ public net.osmand.binary.OsmandOdb.StringTable getDefaultInstanceForType() {
return net.osmand.binary.OsmandOdb.StringTable.getDefaultInstance();
}
- public net.osmand.binary.OsmandOdb.StringTable build() {
- net.osmand.binary.OsmandOdb.StringTable result = buildPartial();
- if (!result.isInitialized()) {
+ @Override
+ public boolean isInitialized() {
+ return result.isInitialized();
+ }
+ @Override
+ public net.osmand.binary.OsmandOdb.StringTable build() {
+ if (result != null && !isInitialized()) {
throw newUninitializedMessageException(result);
}
- return result;
+ return buildPartial();
}
private net.osmand.binary.OsmandOdb.StringTable buildParsed()
throws com.google.protobuf.InvalidProtocolBufferException {
- net.osmand.binary.OsmandOdb.StringTable result = buildPartial();
- if (!result.isInitialized()) {
+ if (!isInitialized()) {
throw newUninitializedMessageException(
result).asInvalidProtocolBufferException();
}
- return result;
+ return buildPartial();
}
- public net.osmand.binary.OsmandOdb.StringTable buildPartial() {
- net.osmand.binary.OsmandOdb.StringTable result = new net.osmand.binary.OsmandOdb.StringTable(this);
- int from_bitField0_ = bitField0_;
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
- s_ = new com.google.protobuf.UnmodifiableLazyStringList(
- s_);
- bitField0_ = (bitField0_ & ~0x00000001);
+ @Override
+ public net.osmand.binary.OsmandOdb.StringTable buildPartial() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "build() has already been called on this Builder.");
}
- result.s_ = s_;
- onBuilt();
- return result;
+ if (result.s_ != java.util.Collections.EMPTY_LIST) {
+ result.s_ =
+ java.util.Collections.unmodifiableList(result.s_);
+ }
+ net.osmand.binary.OsmandOdb.StringTable returnMe = result;
+ result = null;
+ return returnMe;
}
- public Builder mergeFrom(com.google.protobuf.Message other) {
+ @Override
+ public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof net.osmand.binary.OsmandOdb.StringTable) {
return mergeFrom((net.osmand.binary.OsmandOdb.StringTable)other);
} else {
@@ -2436,24 +1416,17 @@ public final class OsmandOdb {
public Builder mergeFrom(net.osmand.binary.OsmandOdb.StringTable other) {
if (other == net.osmand.binary.OsmandOdb.StringTable.getDefaultInstance()) return this;
if (!other.s_.isEmpty()) {
- if (s_.isEmpty()) {
- s_ = other.s_;
- bitField0_ = (bitField0_ & ~0x00000001);
- } else {
- ensureSIsMutable();
- s_.addAll(other.s_);
+ if (result.s_.isEmpty()) {
+ result.s_ = new java.util.ArrayList();
}
- onChanged();
+ result.s_.addAll(other.s_);
}
this.mergeUnknownFields(other.getUnknownFields());
return this;
}
- public final boolean isInitialized() {
- return true;
- }
-
- public Builder mergeFrom(
+ @Override
+ public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
@@ -2465,128 +1438,81 @@ public final class OsmandOdb {
switch (tag) {
case 0:
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
default: {
if (!parseUnknownField(input, unknownFields,
extensionRegistry, tag)) {
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
}
break;
}
case 10: {
- ensureSIsMutable();
- s_.add(input.readBytes());
+ addS(input.readString());
break;
}
}
}
}
- private int bitField0_;
// repeated string s = 1;
- private com.google.protobuf.LazyStringList s_ = com.google.protobuf.LazyStringArrayList.EMPTY;
- private void ensureSIsMutable() {
- if (!((bitField0_ & 0x00000001) == 0x00000001)) {
- s_ = new com.google.protobuf.LazyStringArrayList(s_);
- bitField0_ |= 0x00000001;
- }
- }
- public java.util.List
- getSList() {
- return java.util.Collections.unmodifiableList(s_);
+ public java.util.List getSList() {
+ return java.util.Collections.unmodifiableList(result.s_);
}
public int getSCount() {
- return s_.size();
+ return result.getSCount();
}
- public String getS(int index) {
- return s_.get(index);
+ public java.lang.String getS(int index) {
+ return result.getS(index);
}
- public Builder setS(
- int index, String value) {
+ public Builder setS(int index, java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
- ensureSIsMutable();
- s_.set(index, value);
- onChanged();
+ result.s_.set(index, value);
return this;
}
- public Builder addS(String value) {
+ public Builder addS(java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
- ensureSIsMutable();
- s_.add(value);
- onChanged();
+ if (result.s_.isEmpty()) {
+ result.s_ = new java.util.ArrayList();
+ }
+ result.s_.add(value);
return this;
}
public Builder addAllS(
- java.lang.Iterable values) {
- ensureSIsMutable();
- super.addAll(values, s_);
- onChanged();
+ java.lang.Iterable extends java.lang.String> values) {
+ if (result.s_.isEmpty()) {
+ result.s_ = new java.util.ArrayList();
+ }
+ super.addAll(values, result.s_);
return this;
}
public Builder clearS() {
- s_ = com.google.protobuf.LazyStringArrayList.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000001);
- onChanged();
+ result.s_ = java.util.Collections.emptyList();
return this;
}
- void addS(com.google.protobuf.ByteString value) {
- ensureSIsMutable();
- s_.add(value);
- onChanged();
- }
// @@protoc_insertion_point(builder_scope:StringTable)
}
static {
defaultInstance = new StringTable(true);
+ net.osmand.binary.OsmandOdb.internalForceInit();
defaultInstance.initFields();
}
// @@protoc_insertion_point(class_scope:StringTable)
}
- public interface IndexedStringTableOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // optional string prefix = 1;
- boolean hasPrefix();
- String getPrefix();
-
- // repeated string key = 3;
- java.util.List getKeyList();
- int getKeyCount();
- String getKey(int index);
-
- // repeated uint32 val = 4;
- java.util.List getValList();
- int getValCount();
- int getVal(int index);
-
- // repeated .IndexedStringTable subtables = 5;
- java.util.List
- getSubtablesList();
- net.osmand.binary.OsmandOdb.IndexedStringTable getSubtables(int index);
- int getSubtablesCount();
- java.util.List extends net.osmand.binary.OsmandOdb.IndexedStringTableOrBuilder>
- getSubtablesOrBuilderList();
- net.osmand.binary.OsmandOdb.IndexedStringTableOrBuilder getSubtablesOrBuilder(
- int index);
- }
public static final class IndexedStringTable extends
- com.google.protobuf.GeneratedMessage
- implements IndexedStringTableOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use IndexedStringTable.newBuilder() to construct.
- private IndexedStringTable(Builder builder) {
- super(builder);
+ private IndexedStringTable() {
+ initFields();
}
private IndexedStringTable(boolean noInit) {}
@@ -2595,7 +1521,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public IndexedStringTable getDefaultInstanceForType() {
+ @Override
+ public IndexedStringTable getDefaultInstanceForType() {
return defaultInstance;
}
@@ -2604,170 +1531,119 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_IndexedStringTable_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_IndexedStringTable_fieldAccessorTable;
}
- private int bitField0_;
// optional string prefix = 1;
public static final int PREFIX_FIELD_NUMBER = 1;
- private java.lang.Object prefix_;
- public boolean hasPrefix() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
- }
- public String getPrefix() {
- java.lang.Object ref = prefix_;
- if (ref instanceof String) {
- return (String) ref;
- } else {
- com.google.protobuf.ByteString bs =
- (com.google.protobuf.ByteString) ref;
- String s = bs.toStringUtf8();
- if (com.google.protobuf.Internal.isValidUtf8(bs)) {
- prefix_ = s;
- }
- return s;
- }
- }
- private com.google.protobuf.ByteString getPrefixBytes() {
- java.lang.Object ref = prefix_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((String) ref);
- prefix_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
+ private boolean hasPrefix;
+ private java.lang.String prefix_ = "";
+ public boolean hasPrefix() { return hasPrefix; }
+ public java.lang.String getPrefix() { return prefix_; }
// repeated string key = 3;
public static final int KEY_FIELD_NUMBER = 3;
- private com.google.protobuf.LazyStringList key_;
- public java.util.List
- getKeyList() {
+ private java.util.List key_ =
+ java.util.Collections.emptyList();
+ public java.util.List getKeyList() {
return key_;
}
- public int getKeyCount() {
- return key_.size();
- }
- public String getKey(int index) {
+ public int getKeyCount() { return key_.size(); }
+ public java.lang.String getKey(int index) {
return key_.get(index);
}
// repeated uint32 val = 4;
public static final int VAL_FIELD_NUMBER = 4;
- private java.util.List val_;
- public java.util.List
- getValList() {
+ private java.util.List val_ =
+ java.util.Collections.emptyList();
+ public java.util.List getValList() {
return val_;
}
- public int getValCount() {
- return val_.size();
- }
+ public int getValCount() { return val_.size(); }
public int getVal(int index) {
return val_.get(index);
}
// repeated .IndexedStringTable subtables = 5;
public static final int SUBTABLES_FIELD_NUMBER = 5;
- private java.util.List subtables_;
+ private java.util.List subtables_ =
+ java.util.Collections.emptyList();
public java.util.List getSubtablesList() {
return subtables_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.IndexedStringTableOrBuilder>
- getSubtablesOrBuilderList() {
- return subtables_;
- }
- public int getSubtablesCount() {
- return subtables_.size();
- }
+ public int getSubtablesCount() { return subtables_.size(); }
public net.osmand.binary.OsmandOdb.IndexedStringTable getSubtables(int index) {
return subtables_.get(index);
}
- public net.osmand.binary.OsmandOdb.IndexedStringTableOrBuilder getSubtablesOrBuilder(
- int index) {
- return subtables_.get(index);
- }
private void initFields() {
- prefix_ = "";
- key_ = com.google.protobuf.LazyStringArrayList.EMPTY;
- val_ = java.util.Collections.emptyList();;
- subtables_ = java.util.Collections.emptyList();
}
- private byte memoizedIsInitialized = -1;
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized != -1) return isInitialized == 1;
-
- memoizedIsInitialized = 1;
+ @Override
+ public final boolean isInitialized() {
return true;
}
- public void writeTo(com.google.protobuf.CodedOutputStream output)
+ @Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
- output.writeBytes(1, getPrefixBytes());
+ if (hasPrefix()) {
+ output.writeString(1, getPrefix());
}
- for (int i = 0; i < key_.size(); i++) {
- output.writeBytes(3, key_.getByteString(i));
+ for (java.lang.String element : getKeyList()) {
+ output.writeString(3, element);
}
- for (int i = 0; i < val_.size(); i++) {
- output.writeUInt32(4, val_.get(i));
+ for (int element : getValList()) {
+ output.writeUInt32(4, element);
}
- for (int i = 0; i < subtables_.size(); i++) {
- output.writeMessage(5, subtables_.get(i));
+ for (net.osmand.binary.OsmandOdb.IndexedStringTable element : getSubtablesList()) {
+ output.writeMessage(5, element);
}
getUnknownFields().writeTo(output);
}
private int memoizedSerializedSize = -1;
- public int getSerializedSize() {
+ @Override
+ public int getSerializedSize() {
int size = memoizedSerializedSize;
if (size != -1) return size;
size = 0;
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ if (hasPrefix()) {
size += com.google.protobuf.CodedOutputStream
- .computeBytesSize(1, getPrefixBytes());
+ .computeStringSize(1, getPrefix());
}
{
int dataSize = 0;
- for (int i = 0; i < key_.size(); i++) {
+ for (java.lang.String element : getKeyList()) {
dataSize += com.google.protobuf.CodedOutputStream
- .computeBytesSizeNoTag(key_.getByteString(i));
+ .computeStringSizeNoTag(element);
}
size += dataSize;
size += 1 * getKeyList().size();
}
{
int dataSize = 0;
- for (int i = 0; i < val_.size(); i++) {
+ for (int element : getValList()) {
dataSize += com.google.protobuf.CodedOutputStream
- .computeUInt32SizeNoTag(val_.get(i));
+ .computeUInt32SizeNoTag(element);
}
size += dataSize;
size += 1 * getValList().size();
}
- for (int i = 0; i < subtables_.size(); i++) {
+ for (net.osmand.binary.OsmandOdb.IndexedStringTable element : getSubtablesList()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(5, subtables_.get(i));
+ .computeMessageSize(5, element);
}
size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size;
return size;
}
- private static final long serialVersionUID = 0L;
- @java.lang.Override
- protected java.lang.Object writeReplace()
- throws java.io.ObjectStreamException {
- return super.writeReplace();
- }
-
public static net.osmand.binary.OsmandOdb.IndexedStringTable parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
@@ -2836,131 +1712,104 @@ public final class OsmandOdb {
}
public static Builder newBuilder() { return Builder.create(); }
- public Builder newBuilderForType() { return newBuilder(); }
+ @Override
+ public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder(net.osmand.binary.OsmandOdb.IndexedStringTable prototype) {
return newBuilder().mergeFrom(prototype);
}
- public Builder toBuilder() { return newBuilder(this); }
+ @Override
+ public Builder toBuilder() { return newBuilder(this); }
- @java.lang.Override
- protected Builder newBuilderForType(
- com.google.protobuf.GeneratedMessage.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
public static final class Builder extends
- com.google.protobuf.GeneratedMessage.Builder
- implements net.osmand.binary.OsmandOdb.IndexedStringTableOrBuilder {
- public static final com.google.protobuf.Descriptors.Descriptor
- getDescriptor() {
- return net.osmand.binary.OsmandOdb.internal_static_IndexedStringTable_descriptor;
- }
-
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
- internalGetFieldAccessorTable() {
- return net.osmand.binary.OsmandOdb.internal_static_IndexedStringTable_fieldAccessorTable;
- }
+ com.google.protobuf.GeneratedMessage.Builder {
+ private net.osmand.binary.OsmandOdb.IndexedStringTable result;
// Construct using net.osmand.binary.OsmandOdb.IndexedStringTable.newBuilder()
- private Builder() {
- maybeForceBuilderInitialization();
- }
+ private Builder() {}
- private Builder(BuilderParent parent) {
- super(parent);
- maybeForceBuilderInitialization();
- }
- private void maybeForceBuilderInitialization() {
- if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
- getSubtablesFieldBuilder();
- }
- }
private static Builder create() {
- return new Builder();
+ Builder builder = new Builder();
+ builder.result = new net.osmand.binary.OsmandOdb.IndexedStringTable();
+ return builder;
}
- public Builder clear() {
- super.clear();
- prefix_ = "";
- bitField0_ = (bitField0_ & ~0x00000001);
- key_ = com.google.protobuf.LazyStringArrayList.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000002);
- val_ = java.util.Collections.emptyList();;
- bitField0_ = (bitField0_ & ~0x00000004);
- if (subtablesBuilder_ == null) {
- subtables_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000008);
- } else {
- subtablesBuilder_.clear();
+ @Override
+ protected net.osmand.binary.OsmandOdb.IndexedStringTable internalGetResult() {
+ return result;
+ }
+
+ @Override
+ public Builder clear() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "Cannot call clear() after build().");
}
+ result = new net.osmand.binary.OsmandOdb.IndexedStringTable();
return this;
}
- public Builder clone() {
- return create().mergeFrom(buildPartial());
+ @Override
+ public Builder clone() {
+ return create().mergeFrom(result);
}
- public com.google.protobuf.Descriptors.Descriptor
+ @Override
+ public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return net.osmand.binary.OsmandOdb.IndexedStringTable.getDescriptor();
}
- public net.osmand.binary.OsmandOdb.IndexedStringTable getDefaultInstanceForType() {
+ @Override
+ public net.osmand.binary.OsmandOdb.IndexedStringTable getDefaultInstanceForType() {
return net.osmand.binary.OsmandOdb.IndexedStringTable.getDefaultInstance();
}
- public net.osmand.binary.OsmandOdb.IndexedStringTable build() {
- net.osmand.binary.OsmandOdb.IndexedStringTable result = buildPartial();
- if (!result.isInitialized()) {
+ @Override
+ public boolean isInitialized() {
+ return result.isInitialized();
+ }
+ @Override
+ public net.osmand.binary.OsmandOdb.IndexedStringTable build() {
+ if (result != null && !isInitialized()) {
throw newUninitializedMessageException(result);
}
- return result;
+ return buildPartial();
}
private net.osmand.binary.OsmandOdb.IndexedStringTable buildParsed()
throws com.google.protobuf.InvalidProtocolBufferException {
- net.osmand.binary.OsmandOdb.IndexedStringTable result = buildPartial();
- if (!result.isInitialized()) {
+ if (!isInitialized()) {
throw newUninitializedMessageException(
result).asInvalidProtocolBufferException();
}
- return result;
+ return buildPartial();
}
- public net.osmand.binary.OsmandOdb.IndexedStringTable buildPartial() {
- net.osmand.binary.OsmandOdb.IndexedStringTable result = new net.osmand.binary.OsmandOdb.IndexedStringTable(this);
- int from_bitField0_ = bitField0_;
- int to_bitField0_ = 0;
- if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
- to_bitField0_ |= 0x00000001;
+ @Override
+ public net.osmand.binary.OsmandOdb.IndexedStringTable buildPartial() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "build() has already been called on this Builder.");
}
- result.prefix_ = prefix_;
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
- key_ = new com.google.protobuf.UnmodifiableLazyStringList(
- key_);
- bitField0_ = (bitField0_ & ~0x00000002);
+ if (result.key_ != java.util.Collections.EMPTY_LIST) {
+ result.key_ =
+ java.util.Collections.unmodifiableList(result.key_);
}
- result.key_ = key_;
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
- val_ = java.util.Collections.unmodifiableList(val_);
- bitField0_ = (bitField0_ & ~0x00000004);
+ if (result.val_ != java.util.Collections.EMPTY_LIST) {
+ result.val_ =
+ java.util.Collections.unmodifiableList(result.val_);
}
- result.val_ = val_;
- if (subtablesBuilder_ == null) {
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
- subtables_ = java.util.Collections.unmodifiableList(subtables_);
- bitField0_ = (bitField0_ & ~0x00000008);
- }
- result.subtables_ = subtables_;
- } else {
- result.subtables_ = subtablesBuilder_.build();
+ if (result.subtables_ != java.util.Collections.EMPTY_LIST) {
+ result.subtables_ =
+ java.util.Collections.unmodifiableList(result.subtables_);
}
- result.bitField0_ = to_bitField0_;
- onBuilt();
- return result;
+ net.osmand.binary.OsmandOdb.IndexedStringTable returnMe = result;
+ result = null;
+ return returnMe;
}
- public Builder mergeFrom(com.google.protobuf.Message other) {
+ @Override
+ public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof net.osmand.binary.OsmandOdb.IndexedStringTable) {
return mergeFrom((net.osmand.binary.OsmandOdb.IndexedStringTable)other);
} else {
@@ -2975,60 +1824,29 @@ public final class OsmandOdb {
setPrefix(other.getPrefix());
}
if (!other.key_.isEmpty()) {
- if (key_.isEmpty()) {
- key_ = other.key_;
- bitField0_ = (bitField0_ & ~0x00000002);
- } else {
- ensureKeyIsMutable();
- key_.addAll(other.key_);
+ if (result.key_.isEmpty()) {
+ result.key_ = new java.util.ArrayList();
}
- onChanged();
+ result.key_.addAll(other.key_);
}
if (!other.val_.isEmpty()) {
- if (val_.isEmpty()) {
- val_ = other.val_;
- bitField0_ = (bitField0_ & ~0x00000004);
- } else {
- ensureValIsMutable();
- val_.addAll(other.val_);
+ if (result.val_.isEmpty()) {
+ result.val_ = new java.util.ArrayList();
}
- onChanged();
+ result.val_.addAll(other.val_);
}
- if (subtablesBuilder_ == null) {
- if (!other.subtables_.isEmpty()) {
- if (subtables_.isEmpty()) {
- subtables_ = other.subtables_;
- bitField0_ = (bitField0_ & ~0x00000008);
- } else {
- ensureSubtablesIsMutable();
- subtables_.addAll(other.subtables_);
- }
- onChanged();
- }
- } else {
- if (!other.subtables_.isEmpty()) {
- if (subtablesBuilder_.isEmpty()) {
- subtablesBuilder_.dispose();
- subtablesBuilder_ = null;
- subtables_ = other.subtables_;
- bitField0_ = (bitField0_ & ~0x00000008);
- subtablesBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getSubtablesFieldBuilder() : null;
- } else {
- subtablesBuilder_.addAllMessages(other.subtables_);
- }
+ if (!other.subtables_.isEmpty()) {
+ if (result.subtables_.isEmpty()) {
+ result.subtables_ = new java.util.ArrayList();
}
+ result.subtables_.addAll(other.subtables_);
}
this.mergeUnknownFields(other.getUnknownFields());
return this;
}
- public final boolean isInitialized() {
- return true;
- }
-
- public Builder mergeFrom(
+ @Override
+ public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
@@ -3040,30 +1858,25 @@ public final class OsmandOdb {
switch (tag) {
case 0:
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
default: {
if (!parseUnknownField(input, unknownFields,
extensionRegistry, tag)) {
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
}
break;
}
case 10: {
- bitField0_ |= 0x00000001;
- prefix_ = input.readBytes();
+ setPrefix(input.readString());
break;
}
case 26: {
- ensureKeyIsMutable();
- key_.add(input.readBytes());
+ addKey(input.readString());
break;
}
case 32: {
- ensureValIsMutable();
- val_.add(input.readUInt32());
+ addVal(input.readUInt32());
break;
}
case 34: {
@@ -3085,385 +1898,170 @@ public final class OsmandOdb {
}
}
- private int bitField0_;
// optional string prefix = 1;
- private java.lang.Object prefix_ = "";
public boolean hasPrefix() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
+ return result.hasPrefix();
}
- public String getPrefix() {
- java.lang.Object ref = prefix_;
- if (!(ref instanceof String)) {
- String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
- prefix_ = s;
- return s;
- } else {
- return (String) ref;
- }
+ public java.lang.String getPrefix() {
+ return result.getPrefix();
}
- public Builder setPrefix(String value) {
+ public Builder setPrefix(java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
- bitField0_ |= 0x00000001;
- prefix_ = value;
- onChanged();
+ result.hasPrefix = true;
+ result.prefix_ = value;
return this;
}
public Builder clearPrefix() {
- bitField0_ = (bitField0_ & ~0x00000001);
- prefix_ = getDefaultInstance().getPrefix();
- onChanged();
+ result.hasPrefix = false;
+ result.prefix_ = getDefaultInstance().getPrefix();
return this;
}
- void setPrefix(com.google.protobuf.ByteString value) {
- bitField0_ |= 0x00000001;
- prefix_ = value;
- onChanged();
- }
// repeated string key = 3;
- private com.google.protobuf.LazyStringList key_ = com.google.protobuf.LazyStringArrayList.EMPTY;
- private void ensureKeyIsMutable() {
- if (!((bitField0_ & 0x00000002) == 0x00000002)) {
- key_ = new com.google.protobuf.LazyStringArrayList(key_);
- bitField0_ |= 0x00000002;
- }
- }
- public java.util.List
- getKeyList() {
- return java.util.Collections.unmodifiableList(key_);
+ public java.util.List getKeyList() {
+ return java.util.Collections.unmodifiableList(result.key_);
}
public int getKeyCount() {
- return key_.size();
+ return result.getKeyCount();
}
- public String getKey(int index) {
- return key_.get(index);
+ public java.lang.String getKey(int index) {
+ return result.getKey(index);
}
- public Builder setKey(
- int index, String value) {
+ public Builder setKey(int index, java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
- ensureKeyIsMutable();
- key_.set(index, value);
- onChanged();
+ result.key_.set(index, value);
return this;
}
- public Builder addKey(String value) {
+ public Builder addKey(java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
- ensureKeyIsMutable();
- key_.add(value);
- onChanged();
+ if (result.key_.isEmpty()) {
+ result.key_ = new java.util.ArrayList();
+ }
+ result.key_.add(value);
return this;
}
public Builder addAllKey(
- java.lang.Iterable values) {
- ensureKeyIsMutable();
- super.addAll(values, key_);
- onChanged();
+ java.lang.Iterable extends java.lang.String> values) {
+ if (result.key_.isEmpty()) {
+ result.key_ = new java.util.ArrayList();
+ }
+ super.addAll(values, result.key_);
return this;
}
public Builder clearKey() {
- key_ = com.google.protobuf.LazyStringArrayList.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000002);
- onChanged();
+ result.key_ = java.util.Collections.emptyList();
return this;
}
- void addKey(com.google.protobuf.ByteString value) {
- ensureKeyIsMutable();
- key_.add(value);
- onChanged();
- }
// repeated uint32 val = 4;
- private java.util.List val_ = java.util.Collections.emptyList();;
- private void ensureValIsMutable() {
- if (!((bitField0_ & 0x00000004) == 0x00000004)) {
- val_ = new java.util.ArrayList(val_);
- bitField0_ |= 0x00000004;
- }
- }
- public java.util.List
- getValList() {
- return java.util.Collections.unmodifiableList(val_);
+ public java.util.List getValList() {
+ return java.util.Collections.unmodifiableList(result.val_);
}
public int getValCount() {
- return val_.size();
+ return result.getValCount();
}
public int getVal(int index) {
- return val_.get(index);
+ return result.getVal(index);
}
- public Builder setVal(
- int index, int value) {
- ensureValIsMutable();
- val_.set(index, value);
- onChanged();
+ public Builder setVal(int index, int value) {
+ result.val_.set(index, value);
return this;
}
public Builder addVal(int value) {
- ensureValIsMutable();
- val_.add(value);
- onChanged();
+ if (result.val_.isEmpty()) {
+ result.val_ = new java.util.ArrayList();
+ }
+ result.val_.add(value);
return this;
}
public Builder addAllVal(
java.lang.Iterable extends java.lang.Integer> values) {
- ensureValIsMutable();
- super.addAll(values, val_);
- onChanged();
+ if (result.val_.isEmpty()) {
+ result.val_ = new java.util.ArrayList();
+ }
+ super.addAll(values, result.val_);
return this;
}
public Builder clearVal() {
- val_ = java.util.Collections.emptyList();;
- bitField0_ = (bitField0_ & ~0x00000004);
- onChanged();
+ result.val_ = java.util.Collections.emptyList();
return this;
}
// repeated .IndexedStringTable subtables = 5;
- private java.util.List subtables_ =
- java.util.Collections.emptyList();
- private void ensureSubtablesIsMutable() {
- if (!((bitField0_ & 0x00000008) == 0x00000008)) {
- subtables_ = new java.util.ArrayList(subtables_);
- bitField0_ |= 0x00000008;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.IndexedStringTable, net.osmand.binary.OsmandOdb.IndexedStringTable.Builder, net.osmand.binary.OsmandOdb.IndexedStringTableOrBuilder> subtablesBuilder_;
-
public java.util.List getSubtablesList() {
- if (subtablesBuilder_ == null) {
- return java.util.Collections.unmodifiableList(subtables_);
- } else {
- return subtablesBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.subtables_);
}
public int getSubtablesCount() {
- if (subtablesBuilder_ == null) {
- return subtables_.size();
- } else {
- return subtablesBuilder_.getCount();
- }
+ return result.getSubtablesCount();
}
public net.osmand.binary.OsmandOdb.IndexedStringTable getSubtables(int index) {
- if (subtablesBuilder_ == null) {
- return subtables_.get(index);
- } else {
- return subtablesBuilder_.getMessage(index);
- }
+ return result.getSubtables(index);
}
- public Builder setSubtables(
- int index, net.osmand.binary.OsmandOdb.IndexedStringTable value) {
- if (subtablesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureSubtablesIsMutable();
- subtables_.set(index, value);
- onChanged();
- } else {
- subtablesBuilder_.setMessage(index, value);
+ public Builder setSubtables(int index, net.osmand.binary.OsmandOdb.IndexedStringTable value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.subtables_.set(index, value);
return this;
}
- public Builder setSubtables(
- int index, net.osmand.binary.OsmandOdb.IndexedStringTable.Builder builderForValue) {
- if (subtablesBuilder_ == null) {
- ensureSubtablesIsMutable();
- subtables_.set(index, builderForValue.build());
- onChanged();
- } else {
- subtablesBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setSubtables(int index, net.osmand.binary.OsmandOdb.IndexedStringTable.Builder builderForValue) {
+ result.subtables_.set(index, builderForValue.build());
return this;
}
public Builder addSubtables(net.osmand.binary.OsmandOdb.IndexedStringTable value) {
- if (subtablesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureSubtablesIsMutable();
- subtables_.add(value);
- onChanged();
- } else {
- subtablesBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.subtables_.isEmpty()) {
+ result.subtables_ = new java.util.ArrayList();
+ }
+ result.subtables_.add(value);
return this;
}
- public Builder addSubtables(
- int index, net.osmand.binary.OsmandOdb.IndexedStringTable value) {
- if (subtablesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureSubtablesIsMutable();
- subtables_.add(index, value);
- onChanged();
- } else {
- subtablesBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addSubtables(
- net.osmand.binary.OsmandOdb.IndexedStringTable.Builder builderForValue) {
- if (subtablesBuilder_ == null) {
- ensureSubtablesIsMutable();
- subtables_.add(builderForValue.build());
- onChanged();
- } else {
- subtablesBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addSubtables(
- int index, net.osmand.binary.OsmandOdb.IndexedStringTable.Builder builderForValue) {
- if (subtablesBuilder_ == null) {
- ensureSubtablesIsMutable();
- subtables_.add(index, builderForValue.build());
- onChanged();
- } else {
- subtablesBuilder_.addMessage(index, builderForValue.build());
+ public Builder addSubtables(net.osmand.binary.OsmandOdb.IndexedStringTable.Builder builderForValue) {
+ if (result.subtables_.isEmpty()) {
+ result.subtables_ = new java.util.ArrayList();
}
+ result.subtables_.add(builderForValue.build());
return this;
}
public Builder addAllSubtables(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.IndexedStringTable> values) {
- if (subtablesBuilder_ == null) {
- ensureSubtablesIsMutable();
- super.addAll(values, subtables_);
- onChanged();
- } else {
- subtablesBuilder_.addAllMessages(values);
+ if (result.subtables_.isEmpty()) {
+ result.subtables_ = new java.util.ArrayList();
}
+ super.addAll(values, result.subtables_);
return this;
}
public Builder clearSubtables() {
- if (subtablesBuilder_ == null) {
- subtables_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000008);
- onChanged();
- } else {
- subtablesBuilder_.clear();
- }
+ result.subtables_ = java.util.Collections.emptyList();
return this;
}
- public Builder removeSubtables(int index) {
- if (subtablesBuilder_ == null) {
- ensureSubtablesIsMutable();
- subtables_.remove(index);
- onChanged();
- } else {
- subtablesBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.IndexedStringTable.Builder getSubtablesBuilder(
- int index) {
- return getSubtablesFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.IndexedStringTableOrBuilder getSubtablesOrBuilder(
- int index) {
- if (subtablesBuilder_ == null) {
- return subtables_.get(index); } else {
- return subtablesBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.IndexedStringTableOrBuilder>
- getSubtablesOrBuilderList() {
- if (subtablesBuilder_ != null) {
- return subtablesBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(subtables_);
- }
- }
- public net.osmand.binary.OsmandOdb.IndexedStringTable.Builder addSubtablesBuilder() {
- return getSubtablesFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.IndexedStringTable.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.IndexedStringTable.Builder addSubtablesBuilder(
- int index) {
- return getSubtablesFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.IndexedStringTable.getDefaultInstance());
- }
- public java.util.List
- getSubtablesBuilderList() {
- return getSubtablesFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.IndexedStringTable, net.osmand.binary.OsmandOdb.IndexedStringTable.Builder, net.osmand.binary.OsmandOdb.IndexedStringTableOrBuilder>
- getSubtablesFieldBuilder() {
- if (subtablesBuilder_ == null) {
- subtablesBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.IndexedStringTable, net.osmand.binary.OsmandOdb.IndexedStringTable.Builder, net.osmand.binary.OsmandOdb.IndexedStringTableOrBuilder>(
- subtables_,
- ((bitField0_ & 0x00000008) == 0x00000008),
- getParentForChildren(),
- isClean());
- subtables_ = null;
- }
- return subtablesBuilder_;
- }
// @@protoc_insertion_point(builder_scope:IndexedStringTable)
}
static {
defaultInstance = new IndexedStringTable(true);
+ net.osmand.binary.OsmandOdb.internalForceInit();
defaultInstance.initFields();
}
// @@protoc_insertion_point(class_scope:IndexedStringTable)
}
- public interface OsmAndMapIndexOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // required string name = 2;
- boolean hasName();
- String getName();
-
- // repeated .OsmAndMapIndex.MapEncodingRule rules = 4;
- java.util.List
- getRulesList();
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule getRules(int index);
- int getRulesCount();
- java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRuleOrBuilder>
- getRulesOrBuilderList();
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRuleOrBuilder getRulesOrBuilder(
- int index);
-
- // repeated .OsmAndMapIndex.MapRootLevel levels = 5;
- java.util.List
- getLevelsList();
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel getLevels(int index);
- int getLevelsCount();
- java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevelOrBuilder>
- getLevelsOrBuilderList();
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevelOrBuilder getLevelsOrBuilder(
- int index);
-
- // repeated .OsmAndMapIndex.MapDataBlocks blocks = 7;
- java.util.List
- getBlocksList();
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks getBlocks(int index);
- int getBlocksCount();
- java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocksOrBuilder>
- getBlocksOrBuilderList();
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocksOrBuilder getBlocksOrBuilder(
- int index);
- }
public static final class OsmAndMapIndex extends
- com.google.protobuf.GeneratedMessage
- implements OsmAndMapIndexOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use OsmAndMapIndex.newBuilder() to construct.
- private OsmAndMapIndex(Builder builder) {
- super(builder);
+ private OsmAndMapIndex() {
+ initFields();
}
private OsmAndMapIndex(boolean noInit) {}
@@ -3472,7 +2070,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public OsmAndMapIndex getDefaultInstanceForType() {
+ @Override
+ public OsmAndMapIndex getDefaultInstanceForType() {
return defaultInstance;
}
@@ -3481,40 +2080,17 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_fieldAccessorTable;
}
- public interface MapEncodingRuleOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // required string tag = 3;
- boolean hasTag();
- String getTag();
-
- // optional string value = 5;
- boolean hasValue();
- String getValue();
-
- // optional uint32 id = 7;
- boolean hasId();
- int getId();
-
- // optional uint32 minZoom = 9;
- boolean hasMinZoom();
- int getMinZoom();
-
- // optional uint32 type = 10;
- boolean hasType();
- int getType();
- }
public static final class MapEncodingRule extends
- com.google.protobuf.GeneratedMessage
- implements MapEncodingRuleOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use MapEncodingRule.newBuilder() to construct.
- private MapEncodingRule(Builder builder) {
- super(builder);
+ private MapEncodingRule() {
+ initFields();
}
private MapEncodingRule(boolean noInit) {}
@@ -3523,7 +2099,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public MapEncodingRule getDefaultInstanceForType() {
+ @Override
+ public MapEncodingRule getDefaultInstanceForType() {
return defaultInstance;
}
@@ -3532,185 +2109,109 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapEncodingRule_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapEncodingRule_fieldAccessorTable;
}
- private int bitField0_;
// required string tag = 3;
public static final int TAG_FIELD_NUMBER = 3;
- private java.lang.Object tag_;
- public boolean hasTag() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
- }
- public String getTag() {
- java.lang.Object ref = tag_;
- if (ref instanceof String) {
- return (String) ref;
- } else {
- com.google.protobuf.ByteString bs =
- (com.google.protobuf.ByteString) ref;
- String s = bs.toStringUtf8();
- if (com.google.protobuf.Internal.isValidUtf8(bs)) {
- tag_ = s;
- }
- return s;
- }
- }
- private com.google.protobuf.ByteString getTagBytes() {
- java.lang.Object ref = tag_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((String) ref);
- tag_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
+ private boolean hasTag;
+ private java.lang.String tag_ = "";
+ public boolean hasTag() { return hasTag; }
+ public java.lang.String getTag() { return tag_; }
// optional string value = 5;
public static final int VALUE_FIELD_NUMBER = 5;
- private java.lang.Object value_;
- public boolean hasValue() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
- }
- public String getValue() {
- java.lang.Object ref = value_;
- if (ref instanceof String) {
- return (String) ref;
- } else {
- com.google.protobuf.ByteString bs =
- (com.google.protobuf.ByteString) ref;
- String s = bs.toStringUtf8();
- if (com.google.protobuf.Internal.isValidUtf8(bs)) {
- value_ = s;
- }
- return s;
- }
- }
- private com.google.protobuf.ByteString getValueBytes() {
- java.lang.Object ref = value_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((String) ref);
- value_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
+ private boolean hasValue;
+ private java.lang.String value_ = "";
+ public boolean hasValue() { return hasValue; }
+ public java.lang.String getValue() { return value_; }
// optional uint32 id = 7;
public static final int ID_FIELD_NUMBER = 7;
- private int id_;
- public boolean hasId() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
- }
- public int getId() {
- return id_;
- }
+ private boolean hasId;
+ private int id_ = 0;
+ public boolean hasId() { return hasId; }
+ public int getId() { return id_; }
// optional uint32 minZoom = 9;
public static final int MINZOOM_FIELD_NUMBER = 9;
- private int minZoom_;
- public boolean hasMinZoom() {
- return ((bitField0_ & 0x00000008) == 0x00000008);
- }
- public int getMinZoom() {
- return minZoom_;
- }
+ private boolean hasMinZoom;
+ private int minZoom_ = 0;
+ public boolean hasMinZoom() { return hasMinZoom; }
+ public int getMinZoom() { return minZoom_; }
// optional uint32 type = 10;
public static final int TYPE_FIELD_NUMBER = 10;
- private int type_;
- public boolean hasType() {
- return ((bitField0_ & 0x00000010) == 0x00000010);
- }
- public int getType() {
- return type_;
- }
+ private boolean hasType;
+ private int type_ = 0;
+ public boolean hasType() { return hasType; }
+ public int getType() { return type_; }
private void initFields() {
- tag_ = "";
- value_ = "";
- id_ = 0;
- minZoom_ = 0;
- type_ = 0;
}
- private byte memoizedIsInitialized = -1;
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized != -1) return isInitialized == 1;
-
- if (!hasTag()) {
- memoizedIsInitialized = 0;
- return false;
- }
- memoizedIsInitialized = 1;
+ @Override
+ public final boolean isInitialized() {
+ if (!hasTag) return false;
return true;
}
- public void writeTo(com.google.protobuf.CodedOutputStream output)
+ @Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
- output.writeBytes(3, getTagBytes());
+ if (hasTag()) {
+ output.writeString(3, getTag());
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
- output.writeBytes(5, getValueBytes());
+ if (hasValue()) {
+ output.writeString(5, getValue());
}
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
- output.writeUInt32(7, id_);
+ if (hasId()) {
+ output.writeUInt32(7, getId());
}
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
- output.writeUInt32(9, minZoom_);
+ if (hasMinZoom()) {
+ output.writeUInt32(9, getMinZoom());
}
- if (((bitField0_ & 0x00000010) == 0x00000010)) {
- output.writeUInt32(10, type_);
+ if (hasType()) {
+ output.writeUInt32(10, getType());
}
getUnknownFields().writeTo(output);
}
private int memoizedSerializedSize = -1;
- public int getSerializedSize() {
+ @Override
+ public int getSerializedSize() {
int size = memoizedSerializedSize;
if (size != -1) return size;
size = 0;
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ if (hasTag()) {
size += com.google.protobuf.CodedOutputStream
- .computeBytesSize(3, getTagBytes());
+ .computeStringSize(3, getTag());
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
+ if (hasValue()) {
size += com.google.protobuf.CodedOutputStream
- .computeBytesSize(5, getValueBytes());
+ .computeStringSize(5, getValue());
}
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
+ if (hasId()) {
size += com.google.protobuf.CodedOutputStream
- .computeUInt32Size(7, id_);
+ .computeUInt32Size(7, getId());
}
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
+ if (hasMinZoom()) {
size += com.google.protobuf.CodedOutputStream
- .computeUInt32Size(9, minZoom_);
+ .computeUInt32Size(9, getMinZoom());
}
- if (((bitField0_ & 0x00000010) == 0x00000010)) {
+ if (hasType()) {
size += com.google.protobuf.CodedOutputStream
- .computeUInt32Size(10, type_);
+ .computeUInt32Size(10, getType());
}
size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size;
return size;
}
- private static final long serialVersionUID = 0L;
- @java.lang.Override
- protected java.lang.Object writeReplace()
- throws java.io.ObjectStreamException {
- return super.writeReplace();
- }
-
public static net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
@@ -3779,124 +2280,92 @@ public final class OsmandOdb {
}
public static Builder newBuilder() { return Builder.create(); }
- public Builder newBuilderForType() { return newBuilder(); }
+ @Override
+ public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule prototype) {
return newBuilder().mergeFrom(prototype);
}
- public Builder toBuilder() { return newBuilder(this); }
+ @Override
+ public Builder toBuilder() { return newBuilder(this); }
- @java.lang.Override
- protected Builder newBuilderForType(
- com.google.protobuf.GeneratedMessage.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
public static final class Builder extends
- com.google.protobuf.GeneratedMessage.Builder
- implements net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRuleOrBuilder {
- public static final com.google.protobuf.Descriptors.Descriptor
- getDescriptor() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapEncodingRule_descriptor;
- }
-
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
- internalGetFieldAccessorTable() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapEncodingRule_fieldAccessorTable;
- }
+ com.google.protobuf.GeneratedMessage.Builder {
+ private net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule result;
// Construct using net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.newBuilder()
- private Builder() {
- maybeForceBuilderInitialization();
- }
+ private Builder() {}
- private Builder(BuilderParent parent) {
- super(parent);
- maybeForceBuilderInitialization();
- }
- private void maybeForceBuilderInitialization() {
- if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
- }
- }
private static Builder create() {
- return new Builder();
+ Builder builder = new Builder();
+ builder.result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule();
+ return builder;
}
- public Builder clear() {
- super.clear();
- tag_ = "";
- bitField0_ = (bitField0_ & ~0x00000001);
- value_ = "";
- bitField0_ = (bitField0_ & ~0x00000002);
- id_ = 0;
- bitField0_ = (bitField0_ & ~0x00000004);
- minZoom_ = 0;
- bitField0_ = (bitField0_ & ~0x00000008);
- type_ = 0;
- bitField0_ = (bitField0_ & ~0x00000010);
+ @Override
+ protected net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule internalGetResult() {
+ return result;
+ }
+
+ @Override
+ public Builder clear() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "Cannot call clear() after build().");
+ }
+ result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule();
return this;
}
- public Builder clone() {
- return create().mergeFrom(buildPartial());
+ @Override
+ public Builder clone() {
+ return create().mergeFrom(result);
}
- public com.google.protobuf.Descriptors.Descriptor
+ @Override
+ public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.getDescriptor();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule getDefaultInstanceForType() {
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule getDefaultInstanceForType() {
return net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.getDefaultInstance();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule build() {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule result = buildPartial();
- if (!result.isInitialized()) {
+ @Override
+ public boolean isInitialized() {
+ return result.isInitialized();
+ }
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule build() {
+ if (result != null && !isInitialized()) {
throw newUninitializedMessageException(result);
}
- return result;
+ return buildPartial();
}
private net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule buildParsed()
throws com.google.protobuf.InvalidProtocolBufferException {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule result = buildPartial();
- if (!result.isInitialized()) {
+ if (!isInitialized()) {
throw newUninitializedMessageException(
result).asInvalidProtocolBufferException();
}
- return result;
+ return buildPartial();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule buildPartial() {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule(this);
- int from_bitField0_ = bitField0_;
- int to_bitField0_ = 0;
- if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
- to_bitField0_ |= 0x00000001;
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule buildPartial() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "build() has already been called on this Builder.");
}
- result.tag_ = tag_;
- if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
- to_bitField0_ |= 0x00000002;
- }
- result.value_ = value_;
- if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
- to_bitField0_ |= 0x00000004;
- }
- result.id_ = id_;
- if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
- to_bitField0_ |= 0x00000008;
- }
- result.minZoom_ = minZoom_;
- if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
- to_bitField0_ |= 0x00000010;
- }
- result.type_ = type_;
- result.bitField0_ = to_bitField0_;
- onBuilt();
- return result;
+ net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule returnMe = result;
+ result = null;
+ return returnMe;
}
- public Builder mergeFrom(com.google.protobuf.Message other) {
+ @Override
+ public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule) {
return mergeFrom((net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule)other);
} else {
@@ -3926,15 +2395,8 @@ public final class OsmandOdb {
return this;
}
- public final boolean isInitialized() {
- if (!hasTag()) {
-
- return false;
- }
- return true;
- }
-
- public Builder mergeFrom(
+ @Override
+ public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
@@ -3946,180 +2408,133 @@ public final class OsmandOdb {
switch (tag) {
case 0:
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
default: {
if (!parseUnknownField(input, unknownFields,
extensionRegistry, tag)) {
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
}
break;
}
case 26: {
- bitField0_ |= 0x00000001;
- tag_ = input.readBytes();
+ setTag(input.readString());
break;
}
case 42: {
- bitField0_ |= 0x00000002;
- value_ = input.readBytes();
+ setValue(input.readString());
break;
}
case 56: {
- bitField0_ |= 0x00000004;
- id_ = input.readUInt32();
+ setId(input.readUInt32());
break;
}
case 72: {
- bitField0_ |= 0x00000008;
- minZoom_ = input.readUInt32();
+ setMinZoom(input.readUInt32());
break;
}
case 80: {
- bitField0_ |= 0x00000010;
- type_ = input.readUInt32();
+ setType(input.readUInt32());
break;
}
}
}
}
- private int bitField0_;
// required string tag = 3;
- private java.lang.Object tag_ = "";
public boolean hasTag() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
+ return result.hasTag();
}
- public String getTag() {
- java.lang.Object ref = tag_;
- if (!(ref instanceof String)) {
- String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
- tag_ = s;
- return s;
- } else {
- return (String) ref;
- }
+ public java.lang.String getTag() {
+ return result.getTag();
}
- public Builder setTag(String value) {
+ public Builder setTag(java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
- bitField0_ |= 0x00000001;
- tag_ = value;
- onChanged();
+ result.hasTag = true;
+ result.tag_ = value;
return this;
}
public Builder clearTag() {
- bitField0_ = (bitField0_ & ~0x00000001);
- tag_ = getDefaultInstance().getTag();
- onChanged();
+ result.hasTag = false;
+ result.tag_ = getDefaultInstance().getTag();
return this;
}
- void setTag(com.google.protobuf.ByteString value) {
- bitField0_ |= 0x00000001;
- tag_ = value;
- onChanged();
- }
// optional string value = 5;
- private java.lang.Object value_ = "";
public boolean hasValue() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
+ return result.hasValue();
}
- public String getValue() {
- java.lang.Object ref = value_;
- if (!(ref instanceof String)) {
- String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
- value_ = s;
- return s;
- } else {
- return (String) ref;
- }
+ public java.lang.String getValue() {
+ return result.getValue();
}
- public Builder setValue(String value) {
+ public Builder setValue(java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
- bitField0_ |= 0x00000002;
- value_ = value;
- onChanged();
+ result.hasValue = true;
+ result.value_ = value;
return this;
}
public Builder clearValue() {
- bitField0_ = (bitField0_ & ~0x00000002);
- value_ = getDefaultInstance().getValue();
- onChanged();
+ result.hasValue = false;
+ result.value_ = getDefaultInstance().getValue();
return this;
}
- void setValue(com.google.protobuf.ByteString value) {
- bitField0_ |= 0x00000002;
- value_ = value;
- onChanged();
- }
// optional uint32 id = 7;
- private int id_ ;
public boolean hasId() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
+ return result.hasId();
}
public int getId() {
- return id_;
+ return result.getId();
}
public Builder setId(int value) {
- bitField0_ |= 0x00000004;
- id_ = value;
- onChanged();
+ result.hasId = true;
+ result.id_ = value;
return this;
}
public Builder clearId() {
- bitField0_ = (bitField0_ & ~0x00000004);
- id_ = 0;
- onChanged();
+ result.hasId = false;
+ result.id_ = 0;
return this;
}
// optional uint32 minZoom = 9;
- private int minZoom_ ;
public boolean hasMinZoom() {
- return ((bitField0_ & 0x00000008) == 0x00000008);
+ return result.hasMinZoom();
}
public int getMinZoom() {
- return minZoom_;
+ return result.getMinZoom();
}
public Builder setMinZoom(int value) {
- bitField0_ |= 0x00000008;
- minZoom_ = value;
- onChanged();
+ result.hasMinZoom = true;
+ result.minZoom_ = value;
return this;
}
public Builder clearMinZoom() {
- bitField0_ = (bitField0_ & ~0x00000008);
- minZoom_ = 0;
- onChanged();
+ result.hasMinZoom = false;
+ result.minZoom_ = 0;
return this;
}
// optional uint32 type = 10;
- private int type_ ;
public boolean hasType() {
- return ((bitField0_ & 0x00000010) == 0x00000010);
+ return result.hasType();
}
public int getType() {
- return type_;
+ return result.getType();
}
public Builder setType(int value) {
- bitField0_ |= 0x00000010;
- type_ = value;
- onChanged();
+ result.hasType = true;
+ result.type_ = value;
return this;
}
public Builder clearType() {
- bitField0_ = (bitField0_ & ~0x00000010);
- type_ = 0;
- onChanged();
+ result.hasType = false;
+ result.type_ = 0;
return this;
}
@@ -4128,55 +2543,18 @@ public final class OsmandOdb {
static {
defaultInstance = new MapEncodingRule(true);
+ net.osmand.binary.OsmandOdb.internalForceInit();
defaultInstance.initFields();
}
// @@protoc_insertion_point(class_scope:OsmAndMapIndex.MapEncodingRule)
}
- public interface MapRootLevelOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // required int32 maxZoom = 1;
- boolean hasMaxZoom();
- int getMaxZoom();
-
- // required int32 minZoom = 2;
- boolean hasMinZoom();
- int getMinZoom();
-
- // required int32 left = 3;
- boolean hasLeft();
- int getLeft();
-
- // required int32 right = 4;
- boolean hasRight();
- int getRight();
-
- // required int32 top = 5;
- boolean hasTop();
- int getTop();
-
- // required int32 bottom = 6;
- boolean hasBottom();
- int getBottom();
-
- // repeated .OsmAndMapIndex.MapDataBox boxes = 7;
- java.util.List
- getBoxesList();
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox getBoxes(int index);
- int getBoxesCount();
- java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder>
- getBoxesOrBuilderList();
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder getBoxesOrBuilder(
- int index);
- }
public static final class MapRootLevel extends
- com.google.protobuf.GeneratedMessage
- implements MapRootLevelOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use MapRootLevel.newBuilder() to construct.
- private MapRootLevel(Builder builder) {
- super(builder);
+ private MapRootLevel() {
+ initFields();
}
private MapRootLevel(boolean noInit) {}
@@ -4185,7 +2563,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public MapRootLevel getDefaultInstanceForType() {
+ @Override
+ public MapRootLevel getDefaultInstanceForType() {
return defaultInstance;
}
@@ -4194,214 +2573,150 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapRootLevel_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapRootLevel_fieldAccessorTable;
}
- private int bitField0_;
// required int32 maxZoom = 1;
public static final int MAXZOOM_FIELD_NUMBER = 1;
- private int maxZoom_;
- public boolean hasMaxZoom() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
- }
- public int getMaxZoom() {
- return maxZoom_;
- }
+ private boolean hasMaxZoom;
+ private int maxZoom_ = 0;
+ public boolean hasMaxZoom() { return hasMaxZoom; }
+ public int getMaxZoom() { return maxZoom_; }
// required int32 minZoom = 2;
public static final int MINZOOM_FIELD_NUMBER = 2;
- private int minZoom_;
- public boolean hasMinZoom() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
- }
- public int getMinZoom() {
- return minZoom_;
- }
+ private boolean hasMinZoom;
+ private int minZoom_ = 0;
+ public boolean hasMinZoom() { return hasMinZoom; }
+ public int getMinZoom() { return minZoom_; }
// required int32 left = 3;
public static final int LEFT_FIELD_NUMBER = 3;
- private int left_;
- public boolean hasLeft() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
- }
- public int getLeft() {
- return left_;
- }
+ private boolean hasLeft;
+ private int left_ = 0;
+ public boolean hasLeft() { return hasLeft; }
+ public int getLeft() { return left_; }
// required int32 right = 4;
public static final int RIGHT_FIELD_NUMBER = 4;
- private int right_;
- public boolean hasRight() {
- return ((bitField0_ & 0x00000008) == 0x00000008);
- }
- public int getRight() {
- return right_;
- }
+ private boolean hasRight;
+ private int right_ = 0;
+ public boolean hasRight() { return hasRight; }
+ public int getRight() { return right_; }
// required int32 top = 5;
public static final int TOP_FIELD_NUMBER = 5;
- private int top_;
- public boolean hasTop() {
- return ((bitField0_ & 0x00000010) == 0x00000010);
- }
- public int getTop() {
- return top_;
- }
+ private boolean hasTop;
+ private int top_ = 0;
+ public boolean hasTop() { return hasTop; }
+ public int getTop() { return top_; }
// required int32 bottom = 6;
public static final int BOTTOM_FIELD_NUMBER = 6;
- private int bottom_;
- public boolean hasBottom() {
- return ((bitField0_ & 0x00000020) == 0x00000020);
- }
- public int getBottom() {
- return bottom_;
- }
+ private boolean hasBottom;
+ private int bottom_ = 0;
+ public boolean hasBottom() { return hasBottom; }
+ public int getBottom() { return bottom_; }
// repeated .OsmAndMapIndex.MapDataBox boxes = 7;
public static final int BOXES_FIELD_NUMBER = 7;
- private java.util.List boxes_;
+ private java.util.List boxes_ =
+ java.util.Collections.emptyList();
public java.util.List getBoxesList() {
return boxes_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder>
- getBoxesOrBuilderList() {
- return boxes_;
- }
- public int getBoxesCount() {
- return boxes_.size();
- }
+ public int getBoxesCount() { return boxes_.size(); }
public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox getBoxes(int index) {
return boxes_.get(index);
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder getBoxesOrBuilder(
- int index) {
- return boxes_.get(index);
- }
private void initFields() {
- maxZoom_ = 0;
- minZoom_ = 0;
- left_ = 0;
- right_ = 0;
- top_ = 0;
- bottom_ = 0;
- boxes_ = java.util.Collections.emptyList();
}
- private byte memoizedIsInitialized = -1;
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized != -1) return isInitialized == 1;
-
- if (!hasMaxZoom()) {
- memoizedIsInitialized = 0;
- return false;
+ @Override
+ public final boolean isInitialized() {
+ if (!hasMaxZoom) return false;
+ if (!hasMinZoom) return false;
+ if (!hasLeft) return false;
+ if (!hasRight) return false;
+ if (!hasTop) return false;
+ if (!hasBottom) return false;
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox element : getBoxesList()) {
+ if (!element.isInitialized()) return false;
}
- if (!hasMinZoom()) {
- memoizedIsInitialized = 0;
- return false;
- }
- if (!hasLeft()) {
- memoizedIsInitialized = 0;
- return false;
- }
- if (!hasRight()) {
- memoizedIsInitialized = 0;
- return false;
- }
- if (!hasTop()) {
- memoizedIsInitialized = 0;
- return false;
- }
- if (!hasBottom()) {
- memoizedIsInitialized = 0;
- return false;
- }
- for (int i = 0; i < getBoxesCount(); i++) {
- if (!getBoxes(i).isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
- }
- memoizedIsInitialized = 1;
return true;
}
- public void writeTo(com.google.protobuf.CodedOutputStream output)
+ @Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
- output.writeInt32(1, maxZoom_);
+ if (hasMaxZoom()) {
+ output.writeInt32(1, getMaxZoom());
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
- output.writeInt32(2, minZoom_);
+ if (hasMinZoom()) {
+ output.writeInt32(2, getMinZoom());
}
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
- output.writeInt32(3, left_);
+ if (hasLeft()) {
+ output.writeInt32(3, getLeft());
}
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
- output.writeInt32(4, right_);
+ if (hasRight()) {
+ output.writeInt32(4, getRight());
}
- if (((bitField0_ & 0x00000010) == 0x00000010)) {
- output.writeInt32(5, top_);
+ if (hasTop()) {
+ output.writeInt32(5, getTop());
}
- if (((bitField0_ & 0x00000020) == 0x00000020)) {
- output.writeInt32(6, bottom_);
+ if (hasBottom()) {
+ output.writeInt32(6, getBottom());
}
- for (int i = 0; i < boxes_.size(); i++) {
- output.writeMessage(7, boxes_.get(i));
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox element : getBoxesList()) {
+ output.writeMessage(7, element);
}
getUnknownFields().writeTo(output);
}
private int memoizedSerializedSize = -1;
- public int getSerializedSize() {
+ @Override
+ public int getSerializedSize() {
int size = memoizedSerializedSize;
if (size != -1) return size;
size = 0;
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ if (hasMaxZoom()) {
size += com.google.protobuf.CodedOutputStream
- .computeInt32Size(1, maxZoom_);
+ .computeInt32Size(1, getMaxZoom());
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
+ if (hasMinZoom()) {
size += com.google.protobuf.CodedOutputStream
- .computeInt32Size(2, minZoom_);
+ .computeInt32Size(2, getMinZoom());
}
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
+ if (hasLeft()) {
size += com.google.protobuf.CodedOutputStream
- .computeInt32Size(3, left_);
+ .computeInt32Size(3, getLeft());
}
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
+ if (hasRight()) {
size += com.google.protobuf.CodedOutputStream
- .computeInt32Size(4, right_);
+ .computeInt32Size(4, getRight());
}
- if (((bitField0_ & 0x00000010) == 0x00000010)) {
+ if (hasTop()) {
size += com.google.protobuf.CodedOutputStream
- .computeInt32Size(5, top_);
+ .computeInt32Size(5, getTop());
}
- if (((bitField0_ & 0x00000020) == 0x00000020)) {
+ if (hasBottom()) {
size += com.google.protobuf.CodedOutputStream
- .computeInt32Size(6, bottom_);
+ .computeInt32Size(6, getBottom());
}
- for (int i = 0; i < boxes_.size(); i++) {
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox element : getBoxesList()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(7, boxes_.get(i));
+ .computeMessageSize(7, element);
}
size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size;
return size;
}
- private static final long serialVersionUID = 0L;
- @java.lang.Override
- protected java.lang.Object writeReplace()
- throws java.io.ObjectStreamException {
- return super.writeReplace();
- }
-
public static net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
@@ -4470,146 +2785,96 @@ public final class OsmandOdb {
}
public static Builder newBuilder() { return Builder.create(); }
- public Builder newBuilderForType() { return newBuilder(); }
+ @Override
+ public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel prototype) {
return newBuilder().mergeFrom(prototype);
}
- public Builder toBuilder() { return newBuilder(this); }
+ @Override
+ public Builder toBuilder() { return newBuilder(this); }
- @java.lang.Override
- protected Builder newBuilderForType(
- com.google.protobuf.GeneratedMessage.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
public static final class Builder extends
- com.google.protobuf.GeneratedMessage.Builder
- implements net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevelOrBuilder {
- public static final com.google.protobuf.Descriptors.Descriptor
- getDescriptor() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapRootLevel_descriptor;
- }
-
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
- internalGetFieldAccessorTable() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapRootLevel_fieldAccessorTable;
- }
+ com.google.protobuf.GeneratedMessage.Builder {
+ private net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel result;
// Construct using net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.newBuilder()
- private Builder() {
- maybeForceBuilderInitialization();
- }
+ private Builder() {}
- private Builder(BuilderParent parent) {
- super(parent);
- maybeForceBuilderInitialization();
- }
- private void maybeForceBuilderInitialization() {
- if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
- getBoxesFieldBuilder();
- }
- }
private static Builder create() {
- return new Builder();
+ Builder builder = new Builder();
+ builder.result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel();
+ return builder;
}
- public Builder clear() {
- super.clear();
- maxZoom_ = 0;
- bitField0_ = (bitField0_ & ~0x00000001);
- minZoom_ = 0;
- bitField0_ = (bitField0_ & ~0x00000002);
- left_ = 0;
- bitField0_ = (bitField0_ & ~0x00000004);
- right_ = 0;
- bitField0_ = (bitField0_ & ~0x00000008);
- top_ = 0;
- bitField0_ = (bitField0_ & ~0x00000010);
- bottom_ = 0;
- bitField0_ = (bitField0_ & ~0x00000020);
- if (boxesBuilder_ == null) {
- boxes_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000040);
- } else {
- boxesBuilder_.clear();
+ @Override
+ protected net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel internalGetResult() {
+ return result;
+ }
+
+ @Override
+ public Builder clear() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "Cannot call clear() after build().");
}
+ result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel();
return this;
}
- public Builder clone() {
- return create().mergeFrom(buildPartial());
+ @Override
+ public Builder clone() {
+ return create().mergeFrom(result);
}
- public com.google.protobuf.Descriptors.Descriptor
+ @Override
+ public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.getDescriptor();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel getDefaultInstanceForType() {
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel getDefaultInstanceForType() {
return net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.getDefaultInstance();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel build() {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel result = buildPartial();
- if (!result.isInitialized()) {
+ @Override
+ public boolean isInitialized() {
+ return result.isInitialized();
+ }
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel build() {
+ if (result != null && !isInitialized()) {
throw newUninitializedMessageException(result);
}
- return result;
+ return buildPartial();
}
private net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel buildParsed()
throws com.google.protobuf.InvalidProtocolBufferException {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel result = buildPartial();
- if (!result.isInitialized()) {
+ if (!isInitialized()) {
throw newUninitializedMessageException(
result).asInvalidProtocolBufferException();
}
- return result;
+ return buildPartial();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel buildPartial() {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel(this);
- int from_bitField0_ = bitField0_;
- int to_bitField0_ = 0;
- if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
- to_bitField0_ |= 0x00000001;
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel buildPartial() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "build() has already been called on this Builder.");
}
- result.maxZoom_ = maxZoom_;
- if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
- to_bitField0_ |= 0x00000002;
+ if (result.boxes_ != java.util.Collections.EMPTY_LIST) {
+ result.boxes_ =
+ java.util.Collections.unmodifiableList(result.boxes_);
}
- result.minZoom_ = minZoom_;
- if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
- to_bitField0_ |= 0x00000004;
- }
- result.left_ = left_;
- if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
- to_bitField0_ |= 0x00000008;
- }
- result.right_ = right_;
- if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
- to_bitField0_ |= 0x00000010;
- }
- result.top_ = top_;
- if (((from_bitField0_ & 0x00000020) == 0x00000020)) {
- to_bitField0_ |= 0x00000020;
- }
- result.bottom_ = bottom_;
- if (boxesBuilder_ == null) {
- if (((bitField0_ & 0x00000040) == 0x00000040)) {
- boxes_ = java.util.Collections.unmodifiableList(boxes_);
- bitField0_ = (bitField0_ & ~0x00000040);
- }
- result.boxes_ = boxes_;
- } else {
- result.boxes_ = boxesBuilder_.build();
- }
- result.bitField0_ = to_bitField0_;
- onBuilt();
- return result;
+ net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel returnMe = result;
+ result = null;
+ return returnMe;
}
- public Builder mergeFrom(com.google.protobuf.Message other) {
+ @Override
+ public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel) {
return mergeFrom((net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel)other);
} else {
@@ -4638,71 +2903,18 @@ public final class OsmandOdb {
if (other.hasBottom()) {
setBottom(other.getBottom());
}
- if (boxesBuilder_ == null) {
- if (!other.boxes_.isEmpty()) {
- if (boxes_.isEmpty()) {
- boxes_ = other.boxes_;
- bitField0_ = (bitField0_ & ~0x00000040);
- } else {
- ensureBoxesIsMutable();
- boxes_.addAll(other.boxes_);
- }
- onChanged();
- }
- } else {
- if (!other.boxes_.isEmpty()) {
- if (boxesBuilder_.isEmpty()) {
- boxesBuilder_.dispose();
- boxesBuilder_ = null;
- boxes_ = other.boxes_;
- bitField0_ = (bitField0_ & ~0x00000040);
- boxesBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getBoxesFieldBuilder() : null;
- } else {
- boxesBuilder_.addAllMessages(other.boxes_);
- }
+ if (!other.boxes_.isEmpty()) {
+ if (result.boxes_.isEmpty()) {
+ result.boxes_ = new java.util.ArrayList();
}
+ result.boxes_.addAll(other.boxes_);
}
this.mergeUnknownFields(other.getUnknownFields());
return this;
}
- public final boolean isInitialized() {
- if (!hasMaxZoom()) {
-
- return false;
- }
- if (!hasMinZoom()) {
-
- return false;
- }
- if (!hasLeft()) {
-
- return false;
- }
- if (!hasRight()) {
-
- return false;
- }
- if (!hasTop()) {
-
- return false;
- }
- if (!hasBottom()) {
-
- return false;
- }
- for (int i = 0; i < getBoxesCount(); i++) {
- if (!getBoxes(i).isInitialized()) {
-
- return false;
- }
- }
- return true;
- }
-
- public Builder mergeFrom(
+ @Override
+ public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
@@ -4714,45 +2926,37 @@ public final class OsmandOdb {
switch (tag) {
case 0:
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
default: {
if (!parseUnknownField(input, unknownFields,
extensionRegistry, tag)) {
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
}
break;
}
case 8: {
- bitField0_ |= 0x00000001;
- maxZoom_ = input.readInt32();
+ setMaxZoom(input.readInt32());
break;
}
case 16: {
- bitField0_ |= 0x00000002;
- minZoom_ = input.readInt32();
+ setMinZoom(input.readInt32());
break;
}
case 24: {
- bitField0_ |= 0x00000004;
- left_ = input.readInt32();
+ setLeft(input.readInt32());
break;
}
case 32: {
- bitField0_ |= 0x00000008;
- right_ = input.readInt32();
+ setRight(input.readInt32());
break;
}
case 40: {
- bitField0_ |= 0x00000010;
- top_ = input.readInt32();
+ setTop(input.readInt32());
break;
}
case 48: {
- bitField0_ |= 0x00000020;
- bottom_ = input.readInt32();
+ setBottom(input.readInt32());
break;
}
case 58: {
@@ -4765,370 +2969,183 @@ public final class OsmandOdb {
}
}
- private int bitField0_;
// required int32 maxZoom = 1;
- private int maxZoom_ ;
public boolean hasMaxZoom() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
+ return result.hasMaxZoom();
}
public int getMaxZoom() {
- return maxZoom_;
+ return result.getMaxZoom();
}
public Builder setMaxZoom(int value) {
- bitField0_ |= 0x00000001;
- maxZoom_ = value;
- onChanged();
+ result.hasMaxZoom = true;
+ result.maxZoom_ = value;
return this;
}
public Builder clearMaxZoom() {
- bitField0_ = (bitField0_ & ~0x00000001);
- maxZoom_ = 0;
- onChanged();
+ result.hasMaxZoom = false;
+ result.maxZoom_ = 0;
return this;
}
// required int32 minZoom = 2;
- private int minZoom_ ;
public boolean hasMinZoom() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
+ return result.hasMinZoom();
}
public int getMinZoom() {
- return minZoom_;
+ return result.getMinZoom();
}
public Builder setMinZoom(int value) {
- bitField0_ |= 0x00000002;
- minZoom_ = value;
- onChanged();
+ result.hasMinZoom = true;
+ result.minZoom_ = value;
return this;
}
public Builder clearMinZoom() {
- bitField0_ = (bitField0_ & ~0x00000002);
- minZoom_ = 0;
- onChanged();
+ result.hasMinZoom = false;
+ result.minZoom_ = 0;
return this;
}
// required int32 left = 3;
- private int left_ ;
public boolean hasLeft() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
+ return result.hasLeft();
}
public int getLeft() {
- return left_;
+ return result.getLeft();
}
public Builder setLeft(int value) {
- bitField0_ |= 0x00000004;
- left_ = value;
- onChanged();
+ result.hasLeft = true;
+ result.left_ = value;
return this;
}
public Builder clearLeft() {
- bitField0_ = (bitField0_ & ~0x00000004);
- left_ = 0;
- onChanged();
+ result.hasLeft = false;
+ result.left_ = 0;
return this;
}
// required int32 right = 4;
- private int right_ ;
public boolean hasRight() {
- return ((bitField0_ & 0x00000008) == 0x00000008);
+ return result.hasRight();
}
public int getRight() {
- return right_;
+ return result.getRight();
}
public Builder setRight(int value) {
- bitField0_ |= 0x00000008;
- right_ = value;
- onChanged();
+ result.hasRight = true;
+ result.right_ = value;
return this;
}
public Builder clearRight() {
- bitField0_ = (bitField0_ & ~0x00000008);
- right_ = 0;
- onChanged();
+ result.hasRight = false;
+ result.right_ = 0;
return this;
}
// required int32 top = 5;
- private int top_ ;
public boolean hasTop() {
- return ((bitField0_ & 0x00000010) == 0x00000010);
+ return result.hasTop();
}
public int getTop() {
- return top_;
+ return result.getTop();
}
public Builder setTop(int value) {
- bitField0_ |= 0x00000010;
- top_ = value;
- onChanged();
+ result.hasTop = true;
+ result.top_ = value;
return this;
}
public Builder clearTop() {
- bitField0_ = (bitField0_ & ~0x00000010);
- top_ = 0;
- onChanged();
+ result.hasTop = false;
+ result.top_ = 0;
return this;
}
// required int32 bottom = 6;
- private int bottom_ ;
public boolean hasBottom() {
- return ((bitField0_ & 0x00000020) == 0x00000020);
+ return result.hasBottom();
}
public int getBottom() {
- return bottom_;
+ return result.getBottom();
}
public Builder setBottom(int value) {
- bitField0_ |= 0x00000020;
- bottom_ = value;
- onChanged();
+ result.hasBottom = true;
+ result.bottom_ = value;
return this;
}
public Builder clearBottom() {
- bitField0_ = (bitField0_ & ~0x00000020);
- bottom_ = 0;
- onChanged();
+ result.hasBottom = false;
+ result.bottom_ = 0;
return this;
}
// repeated .OsmAndMapIndex.MapDataBox boxes = 7;
- private java.util.List boxes_ =
- java.util.Collections.emptyList();
- private void ensureBoxesIsMutable() {
- if (!((bitField0_ & 0x00000040) == 0x00000040)) {
- boxes_ = new java.util.ArrayList(boxes_);
- bitField0_ |= 0x00000040;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder> boxesBuilder_;
-
public java.util.List getBoxesList() {
- if (boxesBuilder_ == null) {
- return java.util.Collections.unmodifiableList(boxes_);
- } else {
- return boxesBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.boxes_);
}
public int getBoxesCount() {
- if (boxesBuilder_ == null) {
- return boxes_.size();
- } else {
- return boxesBuilder_.getCount();
- }
+ return result.getBoxesCount();
}
public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox getBoxes(int index) {
- if (boxesBuilder_ == null) {
- return boxes_.get(index);
- } else {
- return boxesBuilder_.getMessage(index);
- }
+ return result.getBoxes(index);
}
- public Builder setBoxes(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox value) {
- if (boxesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBoxesIsMutable();
- boxes_.set(index, value);
- onChanged();
- } else {
- boxesBuilder_.setMessage(index, value);
+ public Builder setBoxes(int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.boxes_.set(index, value);
return this;
}
- public Builder setBoxes(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder builderForValue) {
- if (boxesBuilder_ == null) {
- ensureBoxesIsMutable();
- boxes_.set(index, builderForValue.build());
- onChanged();
- } else {
- boxesBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setBoxes(int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder builderForValue) {
+ result.boxes_.set(index, builderForValue.build());
return this;
}
public Builder addBoxes(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox value) {
- if (boxesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBoxesIsMutable();
- boxes_.add(value);
- onChanged();
- } else {
- boxesBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.boxes_.isEmpty()) {
+ result.boxes_ = new java.util.ArrayList();
+ }
+ result.boxes_.add(value);
return this;
}
- public Builder addBoxes(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox value) {
- if (boxesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBoxesIsMutable();
- boxes_.add(index, value);
- onChanged();
- } else {
- boxesBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addBoxes(
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder builderForValue) {
- if (boxesBuilder_ == null) {
- ensureBoxesIsMutable();
- boxes_.add(builderForValue.build());
- onChanged();
- } else {
- boxesBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addBoxes(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder builderForValue) {
- if (boxesBuilder_ == null) {
- ensureBoxesIsMutable();
- boxes_.add(index, builderForValue.build());
- onChanged();
- } else {
- boxesBuilder_.addMessage(index, builderForValue.build());
+ public Builder addBoxes(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder builderForValue) {
+ if (result.boxes_.isEmpty()) {
+ result.boxes_ = new java.util.ArrayList();
}
+ result.boxes_.add(builderForValue.build());
return this;
}
public Builder addAllBoxes(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox> values) {
- if (boxesBuilder_ == null) {
- ensureBoxesIsMutable();
- super.addAll(values, boxes_);
- onChanged();
- } else {
- boxesBuilder_.addAllMessages(values);
+ if (result.boxes_.isEmpty()) {
+ result.boxes_ = new java.util.ArrayList();
}
+ super.addAll(values, result.boxes_);
return this;
}
public Builder clearBoxes() {
- if (boxesBuilder_ == null) {
- boxes_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000040);
- onChanged();
- } else {
- boxesBuilder_.clear();
- }
+ result.boxes_ = java.util.Collections.emptyList();
return this;
}
- public Builder removeBoxes(int index) {
- if (boxesBuilder_ == null) {
- ensureBoxesIsMutable();
- boxes_.remove(index);
- onChanged();
- } else {
- boxesBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder getBoxesBuilder(
- int index) {
- return getBoxesFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder getBoxesOrBuilder(
- int index) {
- if (boxesBuilder_ == null) {
- return boxes_.get(index); } else {
- return boxesBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder>
- getBoxesOrBuilderList() {
- if (boxesBuilder_ != null) {
- return boxesBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(boxes_);
- }
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder addBoxesBuilder() {
- return getBoxesFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder addBoxesBuilder(
- int index) {
- return getBoxesFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.getDefaultInstance());
- }
- public java.util.List
- getBoxesBuilderList() {
- return getBoxesFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder>
- getBoxesFieldBuilder() {
- if (boxesBuilder_ == null) {
- boxesBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder>(
- boxes_,
- ((bitField0_ & 0x00000040) == 0x00000040),
- getParentForChildren(),
- isClean());
- boxes_ = null;
- }
- return boxesBuilder_;
- }
// @@protoc_insertion_point(builder_scope:OsmAndMapIndex.MapRootLevel)
}
static {
defaultInstance = new MapRootLevel(true);
+ net.osmand.binary.OsmandOdb.internalForceInit();
defaultInstance.initFields();
}
// @@protoc_insertion_point(class_scope:OsmAndMapIndex.MapRootLevel)
}
- public interface MapDataBoxOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // required sint32 left = 1;
- boolean hasLeft();
- int getLeft();
-
- // required sint32 right = 2;
- boolean hasRight();
- int getRight();
-
- // required sint32 top = 3;
- boolean hasTop();
- int getTop();
-
- // required sint32 bottom = 4;
- boolean hasBottom();
- int getBottom();
-
- // optional uint32 shiftToMapData = 5;
- boolean hasShiftToMapData();
- int getShiftToMapData();
-
- // repeated .OsmAndMapIndex.MapDataBox boxes = 7;
- java.util.List
- getBoxesList();
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox getBoxes(int index);
- int getBoxesCount();
- java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder>
- getBoxesOrBuilderList();
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder getBoxesOrBuilder(
- int index);
- }
public static final class MapDataBox extends
- com.google.protobuf.GeneratedMessage
- implements MapDataBoxOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use MapDataBox.newBuilder() to construct.
- private MapDataBox(Builder builder) {
- super(builder);
+ private MapDataBox() {
+ initFields();
}
private MapDataBox(boolean noInit) {}
@@ -5137,7 +3154,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public MapDataBox getDefaultInstanceForType() {
+ @Override
+ public MapDataBox getDefaultInstanceForType() {
return defaultInstance;
}
@@ -5146,188 +3164,148 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapDataBox_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapDataBox_fieldAccessorTable;
}
- private int bitField0_;
// required sint32 left = 1;
public static final int LEFT_FIELD_NUMBER = 1;
- private int left_;
- public boolean hasLeft() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
- }
- public int getLeft() {
- return left_;
- }
+ private boolean hasLeft;
+ private int left_ = 0;
+ public boolean hasLeft() { return hasLeft; }
+ public int getLeft() { return left_; }
// required sint32 right = 2;
public static final int RIGHT_FIELD_NUMBER = 2;
- private int right_;
- public boolean hasRight() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
- }
- public int getRight() {
- return right_;
- }
+ private boolean hasRight;
+ private int right_ = 0;
+ public boolean hasRight() { return hasRight; }
+ public int getRight() { return right_; }
// required sint32 top = 3;
public static final int TOP_FIELD_NUMBER = 3;
- private int top_;
- public boolean hasTop() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
- }
- public int getTop() {
- return top_;
- }
+ private boolean hasTop;
+ private int top_ = 0;
+ public boolean hasTop() { return hasTop; }
+ public int getTop() { return top_; }
// required sint32 bottom = 4;
public static final int BOTTOM_FIELD_NUMBER = 4;
- private int bottom_;
- public boolean hasBottom() {
- return ((bitField0_ & 0x00000008) == 0x00000008);
- }
- public int getBottom() {
- return bottom_;
- }
+ private boolean hasBottom;
+ private int bottom_ = 0;
+ public boolean hasBottom() { return hasBottom; }
+ public int getBottom() { return bottom_; }
- // optional uint32 shiftToMapData = 5;
+ // optional fixed32 shiftToMapData = 5;
public static final int SHIFTTOMAPDATA_FIELD_NUMBER = 5;
- private int shiftToMapData_;
- public boolean hasShiftToMapData() {
- return ((bitField0_ & 0x00000010) == 0x00000010);
- }
- public int getShiftToMapData() {
- return shiftToMapData_;
- }
+ private boolean hasShiftToMapData;
+ private int shiftToMapData_ = 0;
+ public boolean hasShiftToMapData() { return hasShiftToMapData; }
+ public int getShiftToMapData() { return shiftToMapData_; }
+
+ // optional bool ocean = 6;
+ public static final int OCEAN_FIELD_NUMBER = 6;
+ private boolean hasOcean;
+ private boolean ocean_ = false;
+ public boolean hasOcean() { return hasOcean; }
+ public boolean getOcean() { return ocean_; }
// repeated .OsmAndMapIndex.MapDataBox boxes = 7;
public static final int BOXES_FIELD_NUMBER = 7;
- private java.util.List boxes_;
+ private java.util.List boxes_ =
+ java.util.Collections.emptyList();
public java.util.List getBoxesList() {
return boxes_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder>
- getBoxesOrBuilderList() {
- return boxes_;
- }
- public int getBoxesCount() {
- return boxes_.size();
- }
+ public int getBoxesCount() { return boxes_.size(); }
public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox getBoxes(int index) {
return boxes_.get(index);
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder getBoxesOrBuilder(
- int index) {
- return boxes_.get(index);
- }
private void initFields() {
- left_ = 0;
- right_ = 0;
- top_ = 0;
- bottom_ = 0;
- shiftToMapData_ = 0;
- boxes_ = java.util.Collections.emptyList();
}
- private byte memoizedIsInitialized = -1;
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized != -1) return isInitialized == 1;
-
- if (!hasLeft()) {
- memoizedIsInitialized = 0;
- return false;
+ @Override
+ public final boolean isInitialized() {
+ if (!hasLeft) return false;
+ if (!hasRight) return false;
+ if (!hasTop) return false;
+ if (!hasBottom) return false;
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox element : getBoxesList()) {
+ if (!element.isInitialized()) return false;
}
- if (!hasRight()) {
- memoizedIsInitialized = 0;
- return false;
- }
- if (!hasTop()) {
- memoizedIsInitialized = 0;
- return false;
- }
- if (!hasBottom()) {
- memoizedIsInitialized = 0;
- return false;
- }
- for (int i = 0; i < getBoxesCount(); i++) {
- if (!getBoxes(i).isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
- }
- memoizedIsInitialized = 1;
return true;
}
- public void writeTo(com.google.protobuf.CodedOutputStream output)
+ @Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
- output.writeSInt32(1, left_);
+ if (hasLeft()) {
+ output.writeSInt32(1, getLeft());
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
- output.writeSInt32(2, right_);
+ if (hasRight()) {
+ output.writeSInt32(2, getRight());
}
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
- output.writeSInt32(3, top_);
+ if (hasTop()) {
+ output.writeSInt32(3, getTop());
}
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
- output.writeSInt32(4, bottom_);
+ if (hasBottom()) {
+ output.writeSInt32(4, getBottom());
}
- if (((bitField0_ & 0x00000010) == 0x00000010)) {
- output.writeUInt32(5, shiftToMapData_);
+ if (hasShiftToMapData()) {
+ output.writeFixed32(5, getShiftToMapData());
}
- for (int i = 0; i < boxes_.size(); i++) {
- output.writeMessage(7, boxes_.get(i));
+ if (hasOcean()) {
+ output.writeBool(6, getOcean());
+ }
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox element : getBoxesList()) {
+ output.writeMessage(7, element);
}
getUnknownFields().writeTo(output);
}
private int memoizedSerializedSize = -1;
- public int getSerializedSize() {
+ @Override
+ public int getSerializedSize() {
int size = memoizedSerializedSize;
if (size != -1) return size;
size = 0;
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ if (hasLeft()) {
size += com.google.protobuf.CodedOutputStream
- .computeSInt32Size(1, left_);
+ .computeSInt32Size(1, getLeft());
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
+ if (hasRight()) {
size += com.google.protobuf.CodedOutputStream
- .computeSInt32Size(2, right_);
+ .computeSInt32Size(2, getRight());
}
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
+ if (hasTop()) {
size += com.google.protobuf.CodedOutputStream
- .computeSInt32Size(3, top_);
+ .computeSInt32Size(3, getTop());
}
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
+ if (hasBottom()) {
size += com.google.protobuf.CodedOutputStream
- .computeSInt32Size(4, bottom_);
+ .computeSInt32Size(4, getBottom());
}
- if (((bitField0_ & 0x00000010) == 0x00000010)) {
+ if (hasShiftToMapData()) {
size += com.google.protobuf.CodedOutputStream
- .computeUInt32Size(5, shiftToMapData_);
+ .computeFixed32Size(5, getShiftToMapData());
}
- for (int i = 0; i < boxes_.size(); i++) {
+ if (hasOcean()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(7, boxes_.get(i));
+ .computeBoolSize(6, getOcean());
+ }
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox element : getBoxesList()) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(7, element);
}
size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size;
return size;
}
- private static final long serialVersionUID = 0L;
- @java.lang.Override
- protected java.lang.Object writeReplace()
- throws java.io.ObjectStreamException {
- return super.writeReplace();
- }
-
public static net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
@@ -5396,140 +3374,96 @@ public final class OsmandOdb {
}
public static Builder newBuilder() { return Builder.create(); }
- public Builder newBuilderForType() { return newBuilder(); }
+ @Override
+ public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox prototype) {
return newBuilder().mergeFrom(prototype);
}
- public Builder toBuilder() { return newBuilder(this); }
+ @Override
+ public Builder toBuilder() { return newBuilder(this); }
- @java.lang.Override
- protected Builder newBuilderForType(
- com.google.protobuf.GeneratedMessage.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
public static final class Builder extends
- com.google.protobuf.GeneratedMessage.Builder
- implements net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder {
- public static final com.google.protobuf.Descriptors.Descriptor
- getDescriptor() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapDataBox_descriptor;
- }
-
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
- internalGetFieldAccessorTable() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapDataBox_fieldAccessorTable;
- }
+ com.google.protobuf.GeneratedMessage.Builder {
+ private net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox result;
// Construct using net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.newBuilder()
- private Builder() {
- maybeForceBuilderInitialization();
- }
+ private Builder() {}
- private Builder(BuilderParent parent) {
- super(parent);
- maybeForceBuilderInitialization();
- }
- private void maybeForceBuilderInitialization() {
- if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
- getBoxesFieldBuilder();
- }
- }
private static Builder create() {
- return new Builder();
+ Builder builder = new Builder();
+ builder.result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox();
+ return builder;
}
- public Builder clear() {
- super.clear();
- left_ = 0;
- bitField0_ = (bitField0_ & ~0x00000001);
- right_ = 0;
- bitField0_ = (bitField0_ & ~0x00000002);
- top_ = 0;
- bitField0_ = (bitField0_ & ~0x00000004);
- bottom_ = 0;
- bitField0_ = (bitField0_ & ~0x00000008);
- shiftToMapData_ = 0;
- bitField0_ = (bitField0_ & ~0x00000010);
- if (boxesBuilder_ == null) {
- boxes_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000020);
- } else {
- boxesBuilder_.clear();
+ @Override
+ protected net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox internalGetResult() {
+ return result;
+ }
+
+ @Override
+ public Builder clear() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "Cannot call clear() after build().");
}
+ result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox();
return this;
}
- public Builder clone() {
- return create().mergeFrom(buildPartial());
+ @Override
+ public Builder clone() {
+ return create().mergeFrom(result);
}
- public com.google.protobuf.Descriptors.Descriptor
+ @Override
+ public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.getDescriptor();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox getDefaultInstanceForType() {
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox getDefaultInstanceForType() {
return net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.getDefaultInstance();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox build() {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox result = buildPartial();
- if (!result.isInitialized()) {
+ @Override
+ public boolean isInitialized() {
+ return result.isInitialized();
+ }
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox build() {
+ if (result != null && !isInitialized()) {
throw newUninitializedMessageException(result);
}
- return result;
+ return buildPartial();
}
private net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox buildParsed()
throws com.google.protobuf.InvalidProtocolBufferException {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox result = buildPartial();
- if (!result.isInitialized()) {
+ if (!isInitialized()) {
throw newUninitializedMessageException(
result).asInvalidProtocolBufferException();
}
- return result;
+ return buildPartial();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox buildPartial() {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox(this);
- int from_bitField0_ = bitField0_;
- int to_bitField0_ = 0;
- if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
- to_bitField0_ |= 0x00000001;
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox buildPartial() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "build() has already been called on this Builder.");
}
- result.left_ = left_;
- if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
- to_bitField0_ |= 0x00000002;
+ if (result.boxes_ != java.util.Collections.EMPTY_LIST) {
+ result.boxes_ =
+ java.util.Collections.unmodifiableList(result.boxes_);
}
- result.right_ = right_;
- if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
- to_bitField0_ |= 0x00000004;
- }
- result.top_ = top_;
- if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
- to_bitField0_ |= 0x00000008;
- }
- result.bottom_ = bottom_;
- if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
- to_bitField0_ |= 0x00000010;
- }
- result.shiftToMapData_ = shiftToMapData_;
- if (boxesBuilder_ == null) {
- if (((bitField0_ & 0x00000020) == 0x00000020)) {
- boxes_ = java.util.Collections.unmodifiableList(boxes_);
- bitField0_ = (bitField0_ & ~0x00000020);
- }
- result.boxes_ = boxes_;
- } else {
- result.boxes_ = boxesBuilder_.build();
- }
- result.bitField0_ = to_bitField0_;
- onBuilt();
- return result;
+ net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox returnMe = result;
+ result = null;
+ return returnMe;
}
- public Builder mergeFrom(com.google.protobuf.Message other) {
+ @Override
+ public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox) {
return mergeFrom((net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox)other);
} else {
@@ -5555,63 +3489,21 @@ public final class OsmandOdb {
if (other.hasShiftToMapData()) {
setShiftToMapData(other.getShiftToMapData());
}
- if (boxesBuilder_ == null) {
- if (!other.boxes_.isEmpty()) {
- if (boxes_.isEmpty()) {
- boxes_ = other.boxes_;
- bitField0_ = (bitField0_ & ~0x00000020);
- } else {
- ensureBoxesIsMutable();
- boxes_.addAll(other.boxes_);
- }
- onChanged();
- }
- } else {
- if (!other.boxes_.isEmpty()) {
- if (boxesBuilder_.isEmpty()) {
- boxesBuilder_.dispose();
- boxesBuilder_ = null;
- boxes_ = other.boxes_;
- bitField0_ = (bitField0_ & ~0x00000020);
- boxesBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getBoxesFieldBuilder() : null;
- } else {
- boxesBuilder_.addAllMessages(other.boxes_);
- }
+ if (other.hasOcean()) {
+ setOcean(other.getOcean());
+ }
+ if (!other.boxes_.isEmpty()) {
+ if (result.boxes_.isEmpty()) {
+ result.boxes_ = new java.util.ArrayList();
}
+ result.boxes_.addAll(other.boxes_);
}
this.mergeUnknownFields(other.getUnknownFields());
return this;
}
- public final boolean isInitialized() {
- if (!hasLeft()) {
-
- return false;
- }
- if (!hasRight()) {
-
- return false;
- }
- if (!hasTop()) {
-
- return false;
- }
- if (!hasBottom()) {
-
- return false;
- }
- for (int i = 0; i < getBoxesCount(); i++) {
- if (!getBoxes(i).isInitialized()) {
-
- return false;
- }
- }
- return true;
- }
-
- public Builder mergeFrom(
+ @Override
+ public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
@@ -5623,40 +3515,37 @@ public final class OsmandOdb {
switch (tag) {
case 0:
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
default: {
if (!parseUnknownField(input, unknownFields,
extensionRegistry, tag)) {
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
}
break;
}
case 8: {
- bitField0_ |= 0x00000001;
- left_ = input.readSInt32();
+ setLeft(input.readSInt32());
break;
}
case 16: {
- bitField0_ |= 0x00000002;
- right_ = input.readSInt32();
+ setRight(input.readSInt32());
break;
}
case 24: {
- bitField0_ |= 0x00000004;
- top_ = input.readSInt32();
+ setTop(input.readSInt32());
break;
}
case 32: {
- bitField0_ |= 0x00000008;
- bottom_ = input.readSInt32();
+ setBottom(input.readSInt32());
break;
}
- case 40: {
- bitField0_ |= 0x00000010;
- shiftToMapData_ = input.readUInt32();
+ case 45: {
+ setShiftToMapData(input.readFixed32());
+ break;
+ }
+ case 48: {
+ setOcean(input.readBool());
break;
}
case 58: {
@@ -5669,329 +3558,183 @@ public final class OsmandOdb {
}
}
- private int bitField0_;
// required sint32 left = 1;
- private int left_ ;
public boolean hasLeft() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
+ return result.hasLeft();
}
public int getLeft() {
- return left_;
+ return result.getLeft();
}
public Builder setLeft(int value) {
- bitField0_ |= 0x00000001;
- left_ = value;
- onChanged();
+ result.hasLeft = true;
+ result.left_ = value;
return this;
}
public Builder clearLeft() {
- bitField0_ = (bitField0_ & ~0x00000001);
- left_ = 0;
- onChanged();
+ result.hasLeft = false;
+ result.left_ = 0;
return this;
}
// required sint32 right = 2;
- private int right_ ;
public boolean hasRight() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
+ return result.hasRight();
}
public int getRight() {
- return right_;
+ return result.getRight();
}
public Builder setRight(int value) {
- bitField0_ |= 0x00000002;
- right_ = value;
- onChanged();
+ result.hasRight = true;
+ result.right_ = value;
return this;
}
public Builder clearRight() {
- bitField0_ = (bitField0_ & ~0x00000002);
- right_ = 0;
- onChanged();
+ result.hasRight = false;
+ result.right_ = 0;
return this;
}
// required sint32 top = 3;
- private int top_ ;
public boolean hasTop() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
+ return result.hasTop();
}
public int getTop() {
- return top_;
+ return result.getTop();
}
public Builder setTop(int value) {
- bitField0_ |= 0x00000004;
- top_ = value;
- onChanged();
+ result.hasTop = true;
+ result.top_ = value;
return this;
}
public Builder clearTop() {
- bitField0_ = (bitField0_ & ~0x00000004);
- top_ = 0;
- onChanged();
+ result.hasTop = false;
+ result.top_ = 0;
return this;
}
// required sint32 bottom = 4;
- private int bottom_ ;
public boolean hasBottom() {
- return ((bitField0_ & 0x00000008) == 0x00000008);
+ return result.hasBottom();
}
public int getBottom() {
- return bottom_;
+ return result.getBottom();
}
public Builder setBottom(int value) {
- bitField0_ |= 0x00000008;
- bottom_ = value;
- onChanged();
+ result.hasBottom = true;
+ result.bottom_ = value;
return this;
}
public Builder clearBottom() {
- bitField0_ = (bitField0_ & ~0x00000008);
- bottom_ = 0;
- onChanged();
+ result.hasBottom = false;
+ result.bottom_ = 0;
return this;
}
- // optional uint32 shiftToMapData = 5;
- private int shiftToMapData_ ;
+ // optional fixed32 shiftToMapData = 5;
public boolean hasShiftToMapData() {
- return ((bitField0_ & 0x00000010) == 0x00000010);
+ return result.hasShiftToMapData();
}
public int getShiftToMapData() {
- return shiftToMapData_;
+ return result.getShiftToMapData();
}
public Builder setShiftToMapData(int value) {
- bitField0_ |= 0x00000010;
- shiftToMapData_ = value;
- onChanged();
+ result.hasShiftToMapData = true;
+ result.shiftToMapData_ = value;
return this;
}
public Builder clearShiftToMapData() {
- bitField0_ = (bitField0_ & ~0x00000010);
- shiftToMapData_ = 0;
- onChanged();
+ result.hasShiftToMapData = false;
+ result.shiftToMapData_ = 0;
+ return this;
+ }
+
+ // optional bool ocean = 6;
+ public boolean hasOcean() {
+ return result.hasOcean();
+ }
+ public boolean getOcean() {
+ return result.getOcean();
+ }
+ public Builder setOcean(boolean value) {
+ result.hasOcean = true;
+ result.ocean_ = value;
+ return this;
+ }
+ public Builder clearOcean() {
+ result.hasOcean = false;
+ result.ocean_ = false;
return this;
}
// repeated .OsmAndMapIndex.MapDataBox boxes = 7;
- private java.util.List boxes_ =
- java.util.Collections.emptyList();
- private void ensureBoxesIsMutable() {
- if (!((bitField0_ & 0x00000020) == 0x00000020)) {
- boxes_ = new java.util.ArrayList(boxes_);
- bitField0_ |= 0x00000020;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder> boxesBuilder_;
-
public java.util.List getBoxesList() {
- if (boxesBuilder_ == null) {
- return java.util.Collections.unmodifiableList(boxes_);
- } else {
- return boxesBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.boxes_);
}
public int getBoxesCount() {
- if (boxesBuilder_ == null) {
- return boxes_.size();
- } else {
- return boxesBuilder_.getCount();
- }
+ return result.getBoxesCount();
}
public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox getBoxes(int index) {
- if (boxesBuilder_ == null) {
- return boxes_.get(index);
- } else {
- return boxesBuilder_.getMessage(index);
- }
+ return result.getBoxes(index);
}
- public Builder setBoxes(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox value) {
- if (boxesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBoxesIsMutable();
- boxes_.set(index, value);
- onChanged();
- } else {
- boxesBuilder_.setMessage(index, value);
+ public Builder setBoxes(int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.boxes_.set(index, value);
return this;
}
- public Builder setBoxes(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder builderForValue) {
- if (boxesBuilder_ == null) {
- ensureBoxesIsMutable();
- boxes_.set(index, builderForValue.build());
- onChanged();
- } else {
- boxesBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setBoxes(int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder builderForValue) {
+ result.boxes_.set(index, builderForValue.build());
return this;
}
public Builder addBoxes(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox value) {
- if (boxesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBoxesIsMutable();
- boxes_.add(value);
- onChanged();
- } else {
- boxesBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.boxes_.isEmpty()) {
+ result.boxes_ = new java.util.ArrayList();
+ }
+ result.boxes_.add(value);
return this;
}
- public Builder addBoxes(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox value) {
- if (boxesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBoxesIsMutable();
- boxes_.add(index, value);
- onChanged();
- } else {
- boxesBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addBoxes(
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder builderForValue) {
- if (boxesBuilder_ == null) {
- ensureBoxesIsMutable();
- boxes_.add(builderForValue.build());
- onChanged();
- } else {
- boxesBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addBoxes(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder builderForValue) {
- if (boxesBuilder_ == null) {
- ensureBoxesIsMutable();
- boxes_.add(index, builderForValue.build());
- onChanged();
- } else {
- boxesBuilder_.addMessage(index, builderForValue.build());
+ public Builder addBoxes(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder builderForValue) {
+ if (result.boxes_.isEmpty()) {
+ result.boxes_ = new java.util.ArrayList();
}
+ result.boxes_.add(builderForValue.build());
return this;
}
public Builder addAllBoxes(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox> values) {
- if (boxesBuilder_ == null) {
- ensureBoxesIsMutable();
- super.addAll(values, boxes_);
- onChanged();
- } else {
- boxesBuilder_.addAllMessages(values);
+ if (result.boxes_.isEmpty()) {
+ result.boxes_ = new java.util.ArrayList();
}
+ super.addAll(values, result.boxes_);
return this;
}
public Builder clearBoxes() {
- if (boxesBuilder_ == null) {
- boxes_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000020);
- onChanged();
- } else {
- boxesBuilder_.clear();
- }
+ result.boxes_ = java.util.Collections.emptyList();
return this;
}
- public Builder removeBoxes(int index) {
- if (boxesBuilder_ == null) {
- ensureBoxesIsMutable();
- boxes_.remove(index);
- onChanged();
- } else {
- boxesBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder getBoxesBuilder(
- int index) {
- return getBoxesFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder getBoxesOrBuilder(
- int index) {
- if (boxesBuilder_ == null) {
- return boxes_.get(index); } else {
- return boxesBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder>
- getBoxesOrBuilderList() {
- if (boxesBuilder_ != null) {
- return boxesBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(boxes_);
- }
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder addBoxesBuilder() {
- return getBoxesFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder addBoxesBuilder(
- int index) {
- return getBoxesFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.getDefaultInstance());
- }
- public java.util.List
- getBoxesBuilderList() {
- return getBoxesFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder>
- getBoxesFieldBuilder() {
- if (boxesBuilder_ == null) {
- boxesBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBox.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBoxOrBuilder>(
- boxes_,
- ((bitField0_ & 0x00000020) == 0x00000020),
- getParentForChildren(),
- isClean());
- boxes_ = null;
- }
- return boxesBuilder_;
- }
// @@protoc_insertion_point(builder_scope:OsmAndMapIndex.MapDataBox)
}
static {
defaultInstance = new MapDataBox(true);
+ net.osmand.binary.OsmandOdb.internalForceInit();
defaultInstance.initFields();
}
// @@protoc_insertion_point(class_scope:OsmAndMapIndex.MapDataBox)
}
- public interface MapDataBlocksOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // repeated .MapDataBlock block = 6;
- java.util.List
- getBlockList();
- net.osmand.binary.OsmandOdb.MapDataBlock getBlock(int index);
- int getBlockCount();
- java.util.List extends net.osmand.binary.OsmandOdb.MapDataBlockOrBuilder>
- getBlockOrBuilderList();
- net.osmand.binary.OsmandOdb.MapDataBlockOrBuilder getBlockOrBuilder(
- int index);
- }
public static final class MapDataBlocks extends
- com.google.protobuf.GeneratedMessage
- implements MapDataBlocksOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use MapDataBlocks.newBuilder() to construct.
- private MapDataBlocks(Builder builder) {
- super(builder);
+ private MapDataBlocks() {
+ initFields();
}
private MapDataBlocks(boolean noInit) {}
@@ -6000,7 +3743,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public MapDataBlocks getDefaultInstanceForType() {
+ @Override
+ public MapDataBlocks getDefaultInstanceForType() {
return defaultInstance;
}
@@ -6009,81 +3753,60 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapDataBlocks_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapDataBlocks_fieldAccessorTable;
}
// repeated .MapDataBlock block = 6;
public static final int BLOCK_FIELD_NUMBER = 6;
- private java.util.List block_;
+ private java.util.List block_ =
+ java.util.Collections.emptyList();
public java.util.List getBlockList() {
return block_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.MapDataBlockOrBuilder>
- getBlockOrBuilderList() {
- return block_;
- }
- public int getBlockCount() {
- return block_.size();
- }
+ public int getBlockCount() { return block_.size(); }
public net.osmand.binary.OsmandOdb.MapDataBlock getBlock(int index) {
return block_.get(index);
}
- public net.osmand.binary.OsmandOdb.MapDataBlockOrBuilder getBlockOrBuilder(
- int index) {
- return block_.get(index);
- }
private void initFields() {
- block_ = java.util.Collections.emptyList();
}
- private byte memoizedIsInitialized = -1;
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized != -1) return isInitialized == 1;
-
- for (int i = 0; i < getBlockCount(); i++) {
- if (!getBlock(i).isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
+ @Override
+ public final boolean isInitialized() {
+ for (net.osmand.binary.OsmandOdb.MapDataBlock element : getBlockList()) {
+ if (!element.isInitialized()) return false;
}
- memoizedIsInitialized = 1;
return true;
}
- public void writeTo(com.google.protobuf.CodedOutputStream output)
+ @Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
- for (int i = 0; i < block_.size(); i++) {
- output.writeMessage(6, block_.get(i));
+ for (net.osmand.binary.OsmandOdb.MapDataBlock element : getBlockList()) {
+ output.writeMessage(6, element);
}
getUnknownFields().writeTo(output);
}
private int memoizedSerializedSize = -1;
- public int getSerializedSize() {
+ @Override
+ public int getSerializedSize() {
int size = memoizedSerializedSize;
if (size != -1) return size;
size = 0;
- for (int i = 0; i < block_.size(); i++) {
+ for (net.osmand.binary.OsmandOdb.MapDataBlock element : getBlockList()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(6, block_.get(i));
+ .computeMessageSize(6, element);
}
size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size;
return size;
}
- private static final long serialVersionUID = 0L;
- @java.lang.Override
- protected java.lang.Object writeReplace()
- throws java.io.ObjectStreamException {
- return super.writeReplace();
- }
-
public static net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
@@ -6152,108 +3875,96 @@ public final class OsmandOdb {
}
public static Builder newBuilder() { return Builder.create(); }
- public Builder newBuilderForType() { return newBuilder(); }
+ @Override
+ public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks prototype) {
return newBuilder().mergeFrom(prototype);
}
- public Builder toBuilder() { return newBuilder(this); }
+ @Override
+ public Builder toBuilder() { return newBuilder(this); }
- @java.lang.Override
- protected Builder newBuilderForType(
- com.google.protobuf.GeneratedMessage.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
public static final class Builder extends
- com.google.protobuf.GeneratedMessage.Builder
- implements net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocksOrBuilder {
- public static final com.google.protobuf.Descriptors.Descriptor
- getDescriptor() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapDataBlocks_descriptor;
- }
-
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
- internalGetFieldAccessorTable() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_MapDataBlocks_fieldAccessorTable;
- }
+ com.google.protobuf.GeneratedMessage.Builder {
+ private net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks result;
// Construct using net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.newBuilder()
- private Builder() {
- maybeForceBuilderInitialization();
- }
+ private Builder() {}
- private Builder(BuilderParent parent) {
- super(parent);
- maybeForceBuilderInitialization();
- }
- private void maybeForceBuilderInitialization() {
- if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
- getBlockFieldBuilder();
- }
- }
private static Builder create() {
- return new Builder();
+ Builder builder = new Builder();
+ builder.result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks();
+ return builder;
}
- public Builder clear() {
- super.clear();
- if (blockBuilder_ == null) {
- block_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000001);
- } else {
- blockBuilder_.clear();
+ @Override
+ protected net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks internalGetResult() {
+ return result;
+ }
+
+ @Override
+ public Builder clear() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "Cannot call clear() after build().");
}
+ result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks();
return this;
}
- public Builder clone() {
- return create().mergeFrom(buildPartial());
+ @Override
+ public Builder clone() {
+ return create().mergeFrom(result);
}
- public com.google.protobuf.Descriptors.Descriptor
+ @Override
+ public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.getDescriptor();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks getDefaultInstanceForType() {
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks getDefaultInstanceForType() {
return net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.getDefaultInstance();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks build() {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks result = buildPartial();
- if (!result.isInitialized()) {
+ @Override
+ public boolean isInitialized() {
+ return result.isInitialized();
+ }
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks build() {
+ if (result != null && !isInitialized()) {
throw newUninitializedMessageException(result);
}
- return result;
+ return buildPartial();
}
private net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks buildParsed()
throws com.google.protobuf.InvalidProtocolBufferException {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks result = buildPartial();
- if (!result.isInitialized()) {
+ if (!isInitialized()) {
throw newUninitializedMessageException(
result).asInvalidProtocolBufferException();
}
- return result;
+ return buildPartial();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks buildPartial() {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks(this);
- int from_bitField0_ = bitField0_;
- if (blockBuilder_ == null) {
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
- block_ = java.util.Collections.unmodifiableList(block_);
- bitField0_ = (bitField0_ & ~0x00000001);
- }
- result.block_ = block_;
- } else {
- result.block_ = blockBuilder_.build();
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks buildPartial() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "build() has already been called on this Builder.");
}
- onBuilt();
- return result;
+ if (result.block_ != java.util.Collections.EMPTY_LIST) {
+ result.block_ =
+ java.util.Collections.unmodifiableList(result.block_);
+ }
+ net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks returnMe = result;
+ result = null;
+ return returnMe;
}
- public Builder mergeFrom(com.google.protobuf.Message other) {
+ @Override
+ public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks) {
return mergeFrom((net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks)other);
} else {
@@ -6264,47 +3975,18 @@ public final class OsmandOdb {
public Builder mergeFrom(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks other) {
if (other == net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.getDefaultInstance()) return this;
- if (blockBuilder_ == null) {
- if (!other.block_.isEmpty()) {
- if (block_.isEmpty()) {
- block_ = other.block_;
- bitField0_ = (bitField0_ & ~0x00000001);
- } else {
- ensureBlockIsMutable();
- block_.addAll(other.block_);
- }
- onChanged();
- }
- } else {
- if (!other.block_.isEmpty()) {
- if (blockBuilder_.isEmpty()) {
- blockBuilder_.dispose();
- blockBuilder_ = null;
- block_ = other.block_;
- bitField0_ = (bitField0_ & ~0x00000001);
- blockBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getBlockFieldBuilder() : null;
- } else {
- blockBuilder_.addAllMessages(other.block_);
- }
+ if (!other.block_.isEmpty()) {
+ if (result.block_.isEmpty()) {
+ result.block_ = new java.util.ArrayList();
}
+ result.block_.addAll(other.block_);
}
this.mergeUnknownFields(other.getUnknownFields());
return this;
}
- public final boolean isInitialized() {
- for (int i = 0; i < getBlockCount(); i++) {
- if (!getBlock(i).isInitialized()) {
-
- return false;
- }
- }
- return true;
- }
-
- public Builder mergeFrom(
+ @Override
+ public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
@@ -6316,13 +3998,11 @@ public final class OsmandOdb {
switch (tag) {
case 0:
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
default: {
if (!parseUnknownField(input, unknownFields,
extensionRegistry, tag)) {
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
}
break;
@@ -6337,390 +4017,177 @@ public final class OsmandOdb {
}
}
- private int bitField0_;
// repeated .MapDataBlock block = 6;
- private java.util.List block_ =
- java.util.Collections.emptyList();
- private void ensureBlockIsMutable() {
- if (!((bitField0_ & 0x00000001) == 0x00000001)) {
- block_ = new java.util.ArrayList(block_);
- bitField0_ |= 0x00000001;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.MapDataBlock, net.osmand.binary.OsmandOdb.MapDataBlock.Builder, net.osmand.binary.OsmandOdb.MapDataBlockOrBuilder> blockBuilder_;
-
public java.util.List getBlockList() {
- if (blockBuilder_ == null) {
- return java.util.Collections.unmodifiableList(block_);
- } else {
- return blockBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.block_);
}
public int getBlockCount() {
- if (blockBuilder_ == null) {
- return block_.size();
- } else {
- return blockBuilder_.getCount();
- }
+ return result.getBlockCount();
}
public net.osmand.binary.OsmandOdb.MapDataBlock getBlock(int index) {
- if (blockBuilder_ == null) {
- return block_.get(index);
- } else {
- return blockBuilder_.getMessage(index);
- }
+ return result.getBlock(index);
}
- public Builder setBlock(
- int index, net.osmand.binary.OsmandOdb.MapDataBlock value) {
- if (blockBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBlockIsMutable();
- block_.set(index, value);
- onChanged();
- } else {
- blockBuilder_.setMessage(index, value);
+ public Builder setBlock(int index, net.osmand.binary.OsmandOdb.MapDataBlock value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.block_.set(index, value);
return this;
}
- public Builder setBlock(
- int index, net.osmand.binary.OsmandOdb.MapDataBlock.Builder builderForValue) {
- if (blockBuilder_ == null) {
- ensureBlockIsMutable();
- block_.set(index, builderForValue.build());
- onChanged();
- } else {
- blockBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setBlock(int index, net.osmand.binary.OsmandOdb.MapDataBlock.Builder builderForValue) {
+ result.block_.set(index, builderForValue.build());
return this;
}
public Builder addBlock(net.osmand.binary.OsmandOdb.MapDataBlock value) {
- if (blockBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBlockIsMutable();
- block_.add(value);
- onChanged();
- } else {
- blockBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.block_.isEmpty()) {
+ result.block_ = new java.util.ArrayList();
+ }
+ result.block_.add(value);
return this;
}
- public Builder addBlock(
- int index, net.osmand.binary.OsmandOdb.MapDataBlock value) {
- if (blockBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBlockIsMutable();
- block_.add(index, value);
- onChanged();
- } else {
- blockBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addBlock(
- net.osmand.binary.OsmandOdb.MapDataBlock.Builder builderForValue) {
- if (blockBuilder_ == null) {
- ensureBlockIsMutable();
- block_.add(builderForValue.build());
- onChanged();
- } else {
- blockBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addBlock(
- int index, net.osmand.binary.OsmandOdb.MapDataBlock.Builder builderForValue) {
- if (blockBuilder_ == null) {
- ensureBlockIsMutable();
- block_.add(index, builderForValue.build());
- onChanged();
- } else {
- blockBuilder_.addMessage(index, builderForValue.build());
+ public Builder addBlock(net.osmand.binary.OsmandOdb.MapDataBlock.Builder builderForValue) {
+ if (result.block_.isEmpty()) {
+ result.block_ = new java.util.ArrayList();
}
+ result.block_.add(builderForValue.build());
return this;
}
public Builder addAllBlock(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.MapDataBlock> values) {
- if (blockBuilder_ == null) {
- ensureBlockIsMutable();
- super.addAll(values, block_);
- onChanged();
- } else {
- blockBuilder_.addAllMessages(values);
+ if (result.block_.isEmpty()) {
+ result.block_ = new java.util.ArrayList();
}
+ super.addAll(values, result.block_);
return this;
}
public Builder clearBlock() {
- if (blockBuilder_ == null) {
- block_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000001);
- onChanged();
- } else {
- blockBuilder_.clear();
- }
+ result.block_ = java.util.Collections.emptyList();
return this;
}
- public Builder removeBlock(int index) {
- if (blockBuilder_ == null) {
- ensureBlockIsMutable();
- block_.remove(index);
- onChanged();
- } else {
- blockBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.MapDataBlock.Builder getBlockBuilder(
- int index) {
- return getBlockFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.MapDataBlockOrBuilder getBlockOrBuilder(
- int index) {
- if (blockBuilder_ == null) {
- return block_.get(index); } else {
- return blockBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.MapDataBlockOrBuilder>
- getBlockOrBuilderList() {
- if (blockBuilder_ != null) {
- return blockBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(block_);
- }
- }
- public net.osmand.binary.OsmandOdb.MapDataBlock.Builder addBlockBuilder() {
- return getBlockFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.MapDataBlock.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.MapDataBlock.Builder addBlockBuilder(
- int index) {
- return getBlockFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.MapDataBlock.getDefaultInstance());
- }
- public java.util.List
- getBlockBuilderList() {
- return getBlockFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.MapDataBlock, net.osmand.binary.OsmandOdb.MapDataBlock.Builder, net.osmand.binary.OsmandOdb.MapDataBlockOrBuilder>
- getBlockFieldBuilder() {
- if (blockBuilder_ == null) {
- blockBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.MapDataBlock, net.osmand.binary.OsmandOdb.MapDataBlock.Builder, net.osmand.binary.OsmandOdb.MapDataBlockOrBuilder>(
- block_,
- ((bitField0_ & 0x00000001) == 0x00000001),
- getParentForChildren(),
- isClean());
- block_ = null;
- }
- return blockBuilder_;
- }
// @@protoc_insertion_point(builder_scope:OsmAndMapIndex.MapDataBlocks)
}
static {
defaultInstance = new MapDataBlocks(true);
+ net.osmand.binary.OsmandOdb.internalForceInit();
defaultInstance.initFields();
}
// @@protoc_insertion_point(class_scope:OsmAndMapIndex.MapDataBlocks)
}
- private int bitField0_;
// required string name = 2;
public static final int NAME_FIELD_NUMBER = 2;
- private java.lang.Object name_;
- public boolean hasName() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
- }
- public String getName() {
- java.lang.Object ref = name_;
- if (ref instanceof String) {
- return (String) ref;
- } else {
- com.google.protobuf.ByteString bs =
- (com.google.protobuf.ByteString) ref;
- String s = bs.toStringUtf8();
- if (com.google.protobuf.Internal.isValidUtf8(bs)) {
- name_ = s;
- }
- return s;
- }
- }
- private com.google.protobuf.ByteString getNameBytes() {
- java.lang.Object ref = name_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((String) ref);
- name_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
+ private boolean hasName;
+ private java.lang.String name_ = "";
+ public boolean hasName() { return hasName; }
+ public java.lang.String getName() { return name_; }
// repeated .OsmAndMapIndex.MapEncodingRule rules = 4;
public static final int RULES_FIELD_NUMBER = 4;
- private java.util.List rules_;
+ private java.util.List rules_ =
+ java.util.Collections.emptyList();
public java.util.List getRulesList() {
return rules_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRuleOrBuilder>
- getRulesOrBuilderList() {
- return rules_;
- }
- public int getRulesCount() {
- return rules_.size();
- }
+ public int getRulesCount() { return rules_.size(); }
public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule getRules(int index) {
return rules_.get(index);
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRuleOrBuilder getRulesOrBuilder(
- int index) {
- return rules_.get(index);
- }
// repeated .OsmAndMapIndex.MapRootLevel levels = 5;
public static final int LEVELS_FIELD_NUMBER = 5;
- private java.util.List levels_;
+ private java.util.List levels_ =
+ java.util.Collections.emptyList();
public java.util.List getLevelsList() {
return levels_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevelOrBuilder>
- getLevelsOrBuilderList() {
- return levels_;
- }
- public int getLevelsCount() {
- return levels_.size();
- }
+ public int getLevelsCount() { return levels_.size(); }
public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel getLevels(int index) {
return levels_.get(index);
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevelOrBuilder getLevelsOrBuilder(
- int index) {
- return levels_.get(index);
- }
// repeated .OsmAndMapIndex.MapDataBlocks blocks = 7;
public static final int BLOCKS_FIELD_NUMBER = 7;
- private java.util.List blocks_;
+ private java.util.List blocks_ =
+ java.util.Collections.emptyList();
public java.util.List getBlocksList() {
return blocks_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocksOrBuilder>
- getBlocksOrBuilderList() {
- return blocks_;
- }
- public int getBlocksCount() {
- return blocks_.size();
- }
+ public int getBlocksCount() { return blocks_.size(); }
public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks getBlocks(int index) {
return blocks_.get(index);
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocksOrBuilder getBlocksOrBuilder(
- int index) {
- return blocks_.get(index);
- }
private void initFields() {
- name_ = "";
- rules_ = java.util.Collections.emptyList();
- levels_ = java.util.Collections.emptyList();
- blocks_ = java.util.Collections.emptyList();
}
- private byte memoizedIsInitialized = -1;
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized != -1) return isInitialized == 1;
-
- if (!hasName()) {
- memoizedIsInitialized = 0;
- return false;
+ @Override
+ public final boolean isInitialized() {
+ if (!hasName) return false;
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule element : getRulesList()) {
+ if (!element.isInitialized()) return false;
}
- for (int i = 0; i < getRulesCount(); i++) {
- if (!getRules(i).isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel element : getLevelsList()) {
+ if (!element.isInitialized()) return false;
}
- for (int i = 0; i < getLevelsCount(); i++) {
- if (!getLevels(i).isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks element : getBlocksList()) {
+ if (!element.isInitialized()) return false;
}
- for (int i = 0; i < getBlocksCount(); i++) {
- if (!getBlocks(i).isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
- }
- memoizedIsInitialized = 1;
return true;
}
- public void writeTo(com.google.protobuf.CodedOutputStream output)
+ @Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
- output.writeBytes(2, getNameBytes());
+ if (hasName()) {
+ output.writeString(2, getName());
}
- for (int i = 0; i < rules_.size(); i++) {
- output.writeMessage(4, rules_.get(i));
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule element : getRulesList()) {
+ output.writeMessage(4, element);
}
- for (int i = 0; i < levels_.size(); i++) {
- output.writeMessage(5, levels_.get(i));
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel element : getLevelsList()) {
+ output.writeMessage(5, element);
}
- for (int i = 0; i < blocks_.size(); i++) {
- output.writeMessage(7, blocks_.get(i));
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks element : getBlocksList()) {
+ output.writeMessage(7, element);
}
getUnknownFields().writeTo(output);
}
private int memoizedSerializedSize = -1;
- public int getSerializedSize() {
+ @Override
+ public int getSerializedSize() {
int size = memoizedSerializedSize;
if (size != -1) return size;
size = 0;
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ if (hasName()) {
size += com.google.protobuf.CodedOutputStream
- .computeBytesSize(2, getNameBytes());
+ .computeStringSize(2, getName());
}
- for (int i = 0; i < rules_.size(); i++) {
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule element : getRulesList()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(4, rules_.get(i));
+ .computeMessageSize(4, element);
}
- for (int i = 0; i < levels_.size(); i++) {
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel element : getLevelsList()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(5, levels_.get(i));
+ .computeMessageSize(5, element);
}
- for (int i = 0; i < blocks_.size(); i++) {
+ for (net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks element : getBlocksList()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(7, blocks_.get(i));
+ .computeMessageSize(7, element);
}
size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size;
return size;
}
- private static final long serialVersionUID = 0L;
- @java.lang.Override
- protected java.lang.Object writeReplace()
- throws java.io.ObjectStreamException {
- return super.writeReplace();
- }
-
public static net.osmand.binary.OsmandOdb.OsmAndMapIndex parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
@@ -6789,148 +4256,104 @@ public final class OsmandOdb {
}
public static Builder newBuilder() { return Builder.create(); }
- public Builder newBuilderForType() { return newBuilder(); }
+ @Override
+ public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder(net.osmand.binary.OsmandOdb.OsmAndMapIndex prototype) {
return newBuilder().mergeFrom(prototype);
}
- public Builder toBuilder() { return newBuilder(this); }
+ @Override
+ public Builder toBuilder() { return newBuilder(this); }
- @java.lang.Override
- protected Builder newBuilderForType(
- com.google.protobuf.GeneratedMessage.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
public static final class Builder extends
- com.google.protobuf.GeneratedMessage.Builder
- implements net.osmand.binary.OsmandOdb.OsmAndMapIndexOrBuilder {
- public static final com.google.protobuf.Descriptors.Descriptor
- getDescriptor() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_descriptor;
- }
-
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
- internalGetFieldAccessorTable() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndMapIndex_fieldAccessorTable;
- }
+ com.google.protobuf.GeneratedMessage.Builder {
+ private net.osmand.binary.OsmandOdb.OsmAndMapIndex result;
// Construct using net.osmand.binary.OsmandOdb.OsmAndMapIndex.newBuilder()
- private Builder() {
- maybeForceBuilderInitialization();
- }
+ private Builder() {}
- private Builder(BuilderParent parent) {
- super(parent);
- maybeForceBuilderInitialization();
- }
- private void maybeForceBuilderInitialization() {
- if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
- getRulesFieldBuilder();
- getLevelsFieldBuilder();
- getBlocksFieldBuilder();
- }
- }
private static Builder create() {
- return new Builder();
+ Builder builder = new Builder();
+ builder.result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex();
+ return builder;
}
- public Builder clear() {
- super.clear();
- name_ = "";
- bitField0_ = (bitField0_ & ~0x00000001);
- if (rulesBuilder_ == null) {
- rules_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000002);
- } else {
- rulesBuilder_.clear();
- }
- if (levelsBuilder_ == null) {
- levels_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000004);
- } else {
- levelsBuilder_.clear();
- }
- if (blocksBuilder_ == null) {
- blocks_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000008);
- } else {
- blocksBuilder_.clear();
+ @Override
+ protected net.osmand.binary.OsmandOdb.OsmAndMapIndex internalGetResult() {
+ return result;
+ }
+
+ @Override
+ public Builder clear() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "Cannot call clear() after build().");
}
+ result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex();
return this;
}
- public Builder clone() {
- return create().mergeFrom(buildPartial());
+ @Override
+ public Builder clone() {
+ return create().mergeFrom(result);
}
- public com.google.protobuf.Descriptors.Descriptor
+ @Override
+ public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return net.osmand.binary.OsmandOdb.OsmAndMapIndex.getDescriptor();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex getDefaultInstanceForType() {
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex getDefaultInstanceForType() {
return net.osmand.binary.OsmandOdb.OsmAndMapIndex.getDefaultInstance();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex build() {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex result = buildPartial();
- if (!result.isInitialized()) {
+ @Override
+ public boolean isInitialized() {
+ return result.isInitialized();
+ }
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex build() {
+ if (result != null && !isInitialized()) {
throw newUninitializedMessageException(result);
}
- return result;
+ return buildPartial();
}
private net.osmand.binary.OsmandOdb.OsmAndMapIndex buildParsed()
throws com.google.protobuf.InvalidProtocolBufferException {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex result = buildPartial();
- if (!result.isInitialized()) {
+ if (!isInitialized()) {
throw newUninitializedMessageException(
result).asInvalidProtocolBufferException();
}
- return result;
+ return buildPartial();
}
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex buildPartial() {
- net.osmand.binary.OsmandOdb.OsmAndMapIndex result = new net.osmand.binary.OsmandOdb.OsmAndMapIndex(this);
- int from_bitField0_ = bitField0_;
- int to_bitField0_ = 0;
- if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
- to_bitField0_ |= 0x00000001;
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndMapIndex buildPartial() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "build() has already been called on this Builder.");
}
- result.name_ = name_;
- if (rulesBuilder_ == null) {
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
- rules_ = java.util.Collections.unmodifiableList(rules_);
- bitField0_ = (bitField0_ & ~0x00000002);
- }
- result.rules_ = rules_;
- } else {
- result.rules_ = rulesBuilder_.build();
+ if (result.rules_ != java.util.Collections.EMPTY_LIST) {
+ result.rules_ =
+ java.util.Collections.unmodifiableList(result.rules_);
}
- if (levelsBuilder_ == null) {
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
- levels_ = java.util.Collections.unmodifiableList(levels_);
- bitField0_ = (bitField0_ & ~0x00000004);
- }
- result.levels_ = levels_;
- } else {
- result.levels_ = levelsBuilder_.build();
+ if (result.levels_ != java.util.Collections.EMPTY_LIST) {
+ result.levels_ =
+ java.util.Collections.unmodifiableList(result.levels_);
}
- if (blocksBuilder_ == null) {
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
- blocks_ = java.util.Collections.unmodifiableList(blocks_);
- bitField0_ = (bitField0_ & ~0x00000008);
- }
- result.blocks_ = blocks_;
- } else {
- result.blocks_ = blocksBuilder_.build();
+ if (result.blocks_ != java.util.Collections.EMPTY_LIST) {
+ result.blocks_ =
+ java.util.Collections.unmodifiableList(result.blocks_);
}
- result.bitField0_ = to_bitField0_;
- onBuilt();
- return result;
+ net.osmand.binary.OsmandOdb.OsmAndMapIndex returnMe = result;
+ result = null;
+ return returnMe;
}
- public Builder mergeFrom(com.google.protobuf.Message other) {
+ @Override
+ public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof net.osmand.binary.OsmandOdb.OsmAndMapIndex) {
return mergeFrom((net.osmand.binary.OsmandOdb.OsmAndMapIndex)other);
} else {
@@ -6944,115 +4367,30 @@ public final class OsmandOdb {
if (other.hasName()) {
setName(other.getName());
}
- if (rulesBuilder_ == null) {
- if (!other.rules_.isEmpty()) {
- if (rules_.isEmpty()) {
- rules_ = other.rules_;
- bitField0_ = (bitField0_ & ~0x00000002);
- } else {
- ensureRulesIsMutable();
- rules_.addAll(other.rules_);
- }
- onChanged();
- }
- } else {
- if (!other.rules_.isEmpty()) {
- if (rulesBuilder_.isEmpty()) {
- rulesBuilder_.dispose();
- rulesBuilder_ = null;
- rules_ = other.rules_;
- bitField0_ = (bitField0_ & ~0x00000002);
- rulesBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getRulesFieldBuilder() : null;
- } else {
- rulesBuilder_.addAllMessages(other.rules_);
- }
+ if (!other.rules_.isEmpty()) {
+ if (result.rules_.isEmpty()) {
+ result.rules_ = new java.util.ArrayList();
}
+ result.rules_.addAll(other.rules_);
}
- if (levelsBuilder_ == null) {
- if (!other.levels_.isEmpty()) {
- if (levels_.isEmpty()) {
- levels_ = other.levels_;
- bitField0_ = (bitField0_ & ~0x00000004);
- } else {
- ensureLevelsIsMutable();
- levels_.addAll(other.levels_);
- }
- onChanged();
- }
- } else {
- if (!other.levels_.isEmpty()) {
- if (levelsBuilder_.isEmpty()) {
- levelsBuilder_.dispose();
- levelsBuilder_ = null;
- levels_ = other.levels_;
- bitField0_ = (bitField0_ & ~0x00000004);
- levelsBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getLevelsFieldBuilder() : null;
- } else {
- levelsBuilder_.addAllMessages(other.levels_);
- }
+ if (!other.levels_.isEmpty()) {
+ if (result.levels_.isEmpty()) {
+ result.levels_ = new java.util.ArrayList();
}
+ result.levels_.addAll(other.levels_);
}
- if (blocksBuilder_ == null) {
- if (!other.blocks_.isEmpty()) {
- if (blocks_.isEmpty()) {
- blocks_ = other.blocks_;
- bitField0_ = (bitField0_ & ~0x00000008);
- } else {
- ensureBlocksIsMutable();
- blocks_.addAll(other.blocks_);
- }
- onChanged();
- }
- } else {
- if (!other.blocks_.isEmpty()) {
- if (blocksBuilder_.isEmpty()) {
- blocksBuilder_.dispose();
- blocksBuilder_ = null;
- blocks_ = other.blocks_;
- bitField0_ = (bitField0_ & ~0x00000008);
- blocksBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getBlocksFieldBuilder() : null;
- } else {
- blocksBuilder_.addAllMessages(other.blocks_);
- }
+ if (!other.blocks_.isEmpty()) {
+ if (result.blocks_.isEmpty()) {
+ result.blocks_ = new java.util.ArrayList();
}
+ result.blocks_.addAll(other.blocks_);
}
this.mergeUnknownFields(other.getUnknownFields());
return this;
}
- public final boolean isInitialized() {
- if (!hasName()) {
-
- return false;
- }
- for (int i = 0; i < getRulesCount(); i++) {
- if (!getRules(i).isInitialized()) {
-
- return false;
- }
- }
- for (int i = 0; i < getLevelsCount(); i++) {
- if (!getLevels(i).isInitialized()) {
-
- return false;
- }
- }
- for (int i = 0; i < getBlocksCount(); i++) {
- if (!getBlocks(i).isInitialized()) {
-
- return false;
- }
- }
- return true;
- }
-
- public Builder mergeFrom(
+ @Override
+ public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
@@ -7064,20 +4402,17 @@ public final class OsmandOdb {
switch (tag) {
case 0:
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
default: {
if (!parseUnknownField(input, unknownFields,
extensionRegistry, tag)) {
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
}
break;
}
case 18: {
- bitField0_ |= 0x00000001;
- name_ = input.readBytes();
+ setName(input.readString());
break;
}
case 34: {
@@ -7102,641 +4437,198 @@ public final class OsmandOdb {
}
}
- private int bitField0_;
// required string name = 2;
- private java.lang.Object name_ = "";
public boolean hasName() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
+ return result.hasName();
}
- public String getName() {
- java.lang.Object ref = name_;
- if (!(ref instanceof String)) {
- String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
- name_ = s;
- return s;
- } else {
- return (String) ref;
- }
+ public java.lang.String getName() {
+ return result.getName();
}
- public Builder setName(String value) {
+ public Builder setName(java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
- bitField0_ |= 0x00000001;
- name_ = value;
- onChanged();
+ result.hasName = true;
+ result.name_ = value;
return this;
}
public Builder clearName() {
- bitField0_ = (bitField0_ & ~0x00000001);
- name_ = getDefaultInstance().getName();
- onChanged();
+ result.hasName = false;
+ result.name_ = getDefaultInstance().getName();
return this;
}
- void setName(com.google.protobuf.ByteString value) {
- bitField0_ |= 0x00000001;
- name_ = value;
- onChanged();
- }
// repeated .OsmAndMapIndex.MapEncodingRule rules = 4;
- private java.util.List rules_ =
- java.util.Collections.emptyList();
- private void ensureRulesIsMutable() {
- if (!((bitField0_ & 0x00000002) == 0x00000002)) {
- rules_ = new java.util.ArrayList(rules_);
- bitField0_ |= 0x00000002;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRuleOrBuilder> rulesBuilder_;
-
public java.util.List getRulesList() {
- if (rulesBuilder_ == null) {
- return java.util.Collections.unmodifiableList(rules_);
- } else {
- return rulesBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.rules_);
}
public int getRulesCount() {
- if (rulesBuilder_ == null) {
- return rules_.size();
- } else {
- return rulesBuilder_.getCount();
- }
+ return result.getRulesCount();
}
public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule getRules(int index) {
- if (rulesBuilder_ == null) {
- return rules_.get(index);
- } else {
- return rulesBuilder_.getMessage(index);
- }
+ return result.getRules(index);
}
- public Builder setRules(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule value) {
- if (rulesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureRulesIsMutable();
- rules_.set(index, value);
- onChanged();
- } else {
- rulesBuilder_.setMessage(index, value);
+ public Builder setRules(int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.rules_.set(index, value);
return this;
}
- public Builder setRules(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.Builder builderForValue) {
- if (rulesBuilder_ == null) {
- ensureRulesIsMutable();
- rules_.set(index, builderForValue.build());
- onChanged();
- } else {
- rulesBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setRules(int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.Builder builderForValue) {
+ result.rules_.set(index, builderForValue.build());
return this;
}
public Builder addRules(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule value) {
- if (rulesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureRulesIsMutable();
- rules_.add(value);
- onChanged();
- } else {
- rulesBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.rules_.isEmpty()) {
+ result.rules_ = new java.util.ArrayList();
+ }
+ result.rules_.add(value);
return this;
}
- public Builder addRules(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule value) {
- if (rulesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureRulesIsMutable();
- rules_.add(index, value);
- onChanged();
- } else {
- rulesBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addRules(
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.Builder builderForValue) {
- if (rulesBuilder_ == null) {
- ensureRulesIsMutable();
- rules_.add(builderForValue.build());
- onChanged();
- } else {
- rulesBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addRules(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.Builder builderForValue) {
- if (rulesBuilder_ == null) {
- ensureRulesIsMutable();
- rules_.add(index, builderForValue.build());
- onChanged();
- } else {
- rulesBuilder_.addMessage(index, builderForValue.build());
+ public Builder addRules(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.Builder builderForValue) {
+ if (result.rules_.isEmpty()) {
+ result.rules_ = new java.util.ArrayList();
}
+ result.rules_.add(builderForValue.build());
return this;
}
public Builder addAllRules(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule> values) {
- if (rulesBuilder_ == null) {
- ensureRulesIsMutable();
- super.addAll(values, rules_);
- onChanged();
- } else {
- rulesBuilder_.addAllMessages(values);
+ if (result.rules_.isEmpty()) {
+ result.rules_ = new java.util.ArrayList();
}
+ super.addAll(values, result.rules_);
return this;
}
public Builder clearRules() {
- if (rulesBuilder_ == null) {
- rules_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000002);
- onChanged();
- } else {
- rulesBuilder_.clear();
- }
+ result.rules_ = java.util.Collections.emptyList();
return this;
}
- public Builder removeRules(int index) {
- if (rulesBuilder_ == null) {
- ensureRulesIsMutable();
- rules_.remove(index);
- onChanged();
- } else {
- rulesBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.Builder getRulesBuilder(
- int index) {
- return getRulesFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRuleOrBuilder getRulesOrBuilder(
- int index) {
- if (rulesBuilder_ == null) {
- return rules_.get(index); } else {
- return rulesBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRuleOrBuilder>
- getRulesOrBuilderList() {
- if (rulesBuilder_ != null) {
- return rulesBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(rules_);
- }
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.Builder addRulesBuilder() {
- return getRulesFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.Builder addRulesBuilder(
- int index) {
- return getRulesFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.getDefaultInstance());
- }
- public java.util.List
- getRulesBuilderList() {
- return getRulesFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRuleOrBuilder>
- getRulesFieldBuilder() {
- if (rulesBuilder_ == null) {
- rulesBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRule.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapEncodingRuleOrBuilder>(
- rules_,
- ((bitField0_ & 0x00000002) == 0x00000002),
- getParentForChildren(),
- isClean());
- rules_ = null;
- }
- return rulesBuilder_;
- }
// repeated .OsmAndMapIndex.MapRootLevel levels = 5;
- private java.util.List levels_ =
- java.util.Collections.emptyList();
- private void ensureLevelsIsMutable() {
- if (!((bitField0_ & 0x00000004) == 0x00000004)) {
- levels_ = new java.util.ArrayList(levels_);
- bitField0_ |= 0x00000004;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevelOrBuilder> levelsBuilder_;
-
public java.util.List getLevelsList() {
- if (levelsBuilder_ == null) {
- return java.util.Collections.unmodifiableList(levels_);
- } else {
- return levelsBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.levels_);
}
public int getLevelsCount() {
- if (levelsBuilder_ == null) {
- return levels_.size();
- } else {
- return levelsBuilder_.getCount();
- }
+ return result.getLevelsCount();
}
public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel getLevels(int index) {
- if (levelsBuilder_ == null) {
- return levels_.get(index);
- } else {
- return levelsBuilder_.getMessage(index);
- }
+ return result.getLevels(index);
}
- public Builder setLevels(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel value) {
- if (levelsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureLevelsIsMutable();
- levels_.set(index, value);
- onChanged();
- } else {
- levelsBuilder_.setMessage(index, value);
+ public Builder setLevels(int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.levels_.set(index, value);
return this;
}
- public Builder setLevels(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.Builder builderForValue) {
- if (levelsBuilder_ == null) {
- ensureLevelsIsMutable();
- levels_.set(index, builderForValue.build());
- onChanged();
- } else {
- levelsBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setLevels(int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.Builder builderForValue) {
+ result.levels_.set(index, builderForValue.build());
return this;
}
public Builder addLevels(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel value) {
- if (levelsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureLevelsIsMutable();
- levels_.add(value);
- onChanged();
- } else {
- levelsBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.levels_.isEmpty()) {
+ result.levels_ = new java.util.ArrayList();
+ }
+ result.levels_.add(value);
return this;
}
- public Builder addLevels(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel value) {
- if (levelsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureLevelsIsMutable();
- levels_.add(index, value);
- onChanged();
- } else {
- levelsBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addLevels(
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.Builder builderForValue) {
- if (levelsBuilder_ == null) {
- ensureLevelsIsMutable();
- levels_.add(builderForValue.build());
- onChanged();
- } else {
- levelsBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addLevels(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.Builder builderForValue) {
- if (levelsBuilder_ == null) {
- ensureLevelsIsMutable();
- levels_.add(index, builderForValue.build());
- onChanged();
- } else {
- levelsBuilder_.addMessage(index, builderForValue.build());
+ public Builder addLevels(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.Builder builderForValue) {
+ if (result.levels_.isEmpty()) {
+ result.levels_ = new java.util.ArrayList();
}
+ result.levels_.add(builderForValue.build());
return this;
}
public Builder addAllLevels(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel> values) {
- if (levelsBuilder_ == null) {
- ensureLevelsIsMutable();
- super.addAll(values, levels_);
- onChanged();
- } else {
- levelsBuilder_.addAllMessages(values);
+ if (result.levels_.isEmpty()) {
+ result.levels_ = new java.util.ArrayList();
}
+ super.addAll(values, result.levels_);
return this;
}
public Builder clearLevels() {
- if (levelsBuilder_ == null) {
- levels_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000004);
- onChanged();
- } else {
- levelsBuilder_.clear();
- }
+ result.levels_ = java.util.Collections.emptyList();
return this;
}
- public Builder removeLevels(int index) {
- if (levelsBuilder_ == null) {
- ensureLevelsIsMutable();
- levels_.remove(index);
- onChanged();
- } else {
- levelsBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.Builder getLevelsBuilder(
- int index) {
- return getLevelsFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevelOrBuilder getLevelsOrBuilder(
- int index) {
- if (levelsBuilder_ == null) {
- return levels_.get(index); } else {
- return levelsBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevelOrBuilder>
- getLevelsOrBuilderList() {
- if (levelsBuilder_ != null) {
- return levelsBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(levels_);
- }
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.Builder addLevelsBuilder() {
- return getLevelsFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.Builder addLevelsBuilder(
- int index) {
- return getLevelsFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.getDefaultInstance());
- }
- public java.util.List
- getLevelsBuilderList() {
- return getLevelsFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevelOrBuilder>
- getLevelsFieldBuilder() {
- if (levelsBuilder_ == null) {
- levelsBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevel.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapRootLevelOrBuilder>(
- levels_,
- ((bitField0_ & 0x00000004) == 0x00000004),
- getParentForChildren(),
- isClean());
- levels_ = null;
- }
- return levelsBuilder_;
- }
// repeated .OsmAndMapIndex.MapDataBlocks blocks = 7;
- private java.util.List blocks_ =
- java.util.Collections.emptyList();
- private void ensureBlocksIsMutable() {
- if (!((bitField0_ & 0x00000008) == 0x00000008)) {
- blocks_ = new java.util.ArrayList(blocks_);
- bitField0_ |= 0x00000008;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocksOrBuilder> blocksBuilder_;
-
public java.util.List getBlocksList() {
- if (blocksBuilder_ == null) {
- return java.util.Collections.unmodifiableList(blocks_);
- } else {
- return blocksBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.blocks_);
}
public int getBlocksCount() {
- if (blocksBuilder_ == null) {
- return blocks_.size();
- } else {
- return blocksBuilder_.getCount();
- }
+ return result.getBlocksCount();
}
public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks getBlocks(int index) {
- if (blocksBuilder_ == null) {
- return blocks_.get(index);
- } else {
- return blocksBuilder_.getMessage(index);
- }
+ return result.getBlocks(index);
}
- public Builder setBlocks(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks value) {
- if (blocksBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBlocksIsMutable();
- blocks_.set(index, value);
- onChanged();
- } else {
- blocksBuilder_.setMessage(index, value);
+ public Builder setBlocks(int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.blocks_.set(index, value);
return this;
}
- public Builder setBlocks(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.Builder builderForValue) {
- if (blocksBuilder_ == null) {
- ensureBlocksIsMutable();
- blocks_.set(index, builderForValue.build());
- onChanged();
- } else {
- blocksBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setBlocks(int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.Builder builderForValue) {
+ result.blocks_.set(index, builderForValue.build());
return this;
}
public Builder addBlocks(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks value) {
- if (blocksBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBlocksIsMutable();
- blocks_.add(value);
- onChanged();
- } else {
- blocksBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.blocks_.isEmpty()) {
+ result.blocks_ = new java.util.ArrayList();
+ }
+ result.blocks_.add(value);
return this;
}
- public Builder addBlocks(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks value) {
- if (blocksBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBlocksIsMutable();
- blocks_.add(index, value);
- onChanged();
- } else {
- blocksBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addBlocks(
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.Builder builderForValue) {
- if (blocksBuilder_ == null) {
- ensureBlocksIsMutable();
- blocks_.add(builderForValue.build());
- onChanged();
- } else {
- blocksBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addBlocks(
- int index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.Builder builderForValue) {
- if (blocksBuilder_ == null) {
- ensureBlocksIsMutable();
- blocks_.add(index, builderForValue.build());
- onChanged();
- } else {
- blocksBuilder_.addMessage(index, builderForValue.build());
+ public Builder addBlocks(net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.Builder builderForValue) {
+ if (result.blocks_.isEmpty()) {
+ result.blocks_ = new java.util.ArrayList();
}
+ result.blocks_.add(builderForValue.build());
return this;
}
public Builder addAllBlocks(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks> values) {
- if (blocksBuilder_ == null) {
- ensureBlocksIsMutable();
- super.addAll(values, blocks_);
- onChanged();
- } else {
- blocksBuilder_.addAllMessages(values);
+ if (result.blocks_.isEmpty()) {
+ result.blocks_ = new java.util.ArrayList();
}
+ super.addAll(values, result.blocks_);
return this;
}
public Builder clearBlocks() {
- if (blocksBuilder_ == null) {
- blocks_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000008);
- onChanged();
- } else {
- blocksBuilder_.clear();
- }
+ result.blocks_ = java.util.Collections.emptyList();
return this;
}
- public Builder removeBlocks(int index) {
- if (blocksBuilder_ == null) {
- ensureBlocksIsMutable();
- blocks_.remove(index);
- onChanged();
- } else {
- blocksBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.Builder getBlocksBuilder(
- int index) {
- return getBlocksFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocksOrBuilder getBlocksOrBuilder(
- int index) {
- if (blocksBuilder_ == null) {
- return blocks_.get(index); } else {
- return blocksBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocksOrBuilder>
- getBlocksOrBuilderList() {
- if (blocksBuilder_ != null) {
- return blocksBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(blocks_);
- }
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.Builder addBlocksBuilder() {
- return getBlocksFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.Builder addBlocksBuilder(
- int index) {
- return getBlocksFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.getDefaultInstance());
- }
- public java.util.List
- getBlocksBuilderList() {
- return getBlocksFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocksOrBuilder>
- getBlocksFieldBuilder() {
- if (blocksBuilder_ == null) {
- blocksBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocks.Builder, net.osmand.binary.OsmandOdb.OsmAndMapIndex.MapDataBlocksOrBuilder>(
- blocks_,
- ((bitField0_ & 0x00000008) == 0x00000008),
- getParentForChildren(),
- isClean());
- blocks_ = null;
- }
- return blocksBuilder_;
- }
// @@protoc_insertion_point(builder_scope:OsmAndMapIndex)
}
static {
defaultInstance = new OsmAndMapIndex(true);
+ net.osmand.binary.OsmandOdb.internalForceInit();
defaultInstance.initFields();
}
// @@protoc_insertion_point(class_scope:OsmAndMapIndex)
}
- public interface MapDataBlockOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // optional uint64 baseId = 10;
- boolean hasBaseId();
- long getBaseId();
-
- // repeated .MapData dataObjects = 12;
- java.util.List
- getDataObjectsList();
- net.osmand.binary.OsmandOdb.MapData getDataObjects(int index);
- int getDataObjectsCount();
- java.util.List extends net.osmand.binary.OsmandOdb.MapDataOrBuilder>
- getDataObjectsOrBuilderList();
- net.osmand.binary.OsmandOdb.MapDataOrBuilder getDataObjectsOrBuilder(
- int index);
-
- // optional .StringTable stringTable = 15;
- boolean hasStringTable();
- net.osmand.binary.OsmandOdb.StringTable getStringTable();
- net.osmand.binary.OsmandOdb.StringTableOrBuilder getStringTableOrBuilder();
- }
public static final class MapDataBlock extends
- com.google.protobuf.GeneratedMessage
- implements MapDataBlockOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use MapDataBlock.newBuilder() to construct.
- private MapDataBlock(Builder builder) {
- super(builder);
+ private MapDataBlock() {
+ initFields();
}
private MapDataBlock(boolean noInit) {}
@@ -7745,7 +4637,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public MapDataBlock getDefaultInstanceForType() {
+ @Override
+ public MapDataBlock getDefaultInstanceForType() {
return defaultInstance;
}
@@ -7754,121 +4647,89 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_MapDataBlock_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_MapDataBlock_fieldAccessorTable;
}
- private int bitField0_;
// optional uint64 baseId = 10;
public static final int BASEID_FIELD_NUMBER = 10;
- private long baseId_;
- public boolean hasBaseId() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
- }
- public long getBaseId() {
- return baseId_;
- }
+ private boolean hasBaseId;
+ private long baseId_ = 0L;
+ public boolean hasBaseId() { return hasBaseId; }
+ public long getBaseId() { return baseId_; }
// repeated .MapData dataObjects = 12;
public static final int DATAOBJECTS_FIELD_NUMBER = 12;
- private java.util.List dataObjects_;
+ private java.util.List dataObjects_ =
+ java.util.Collections.emptyList();
public java.util.List getDataObjectsList() {
return dataObjects_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.MapDataOrBuilder>
- getDataObjectsOrBuilderList() {
- return dataObjects_;
- }
- public int getDataObjectsCount() {
- return dataObjects_.size();
- }
+ public int getDataObjectsCount() { return dataObjects_.size(); }
public net.osmand.binary.OsmandOdb.MapData getDataObjects(int index) {
return dataObjects_.get(index);
}
- public net.osmand.binary.OsmandOdb.MapDataOrBuilder getDataObjectsOrBuilder(
- int index) {
- return dataObjects_.get(index);
- }
// optional .StringTable stringTable = 15;
public static final int STRINGTABLE_FIELD_NUMBER = 15;
+ private boolean hasStringTable;
private net.osmand.binary.OsmandOdb.StringTable stringTable_;
- public boolean hasStringTable() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
- }
- public net.osmand.binary.OsmandOdb.StringTable getStringTable() {
- return stringTable_;
- }
- public net.osmand.binary.OsmandOdb.StringTableOrBuilder getStringTableOrBuilder() {
- return stringTable_;
- }
+ public boolean hasStringTable() { return hasStringTable; }
+ public net.osmand.binary.OsmandOdb.StringTable getStringTable() { return stringTable_; }
private void initFields() {
- baseId_ = 0L;
- dataObjects_ = java.util.Collections.emptyList();
stringTable_ = net.osmand.binary.OsmandOdb.StringTable.getDefaultInstance();
}
- private byte memoizedIsInitialized = -1;
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized != -1) return isInitialized == 1;
-
- for (int i = 0; i < getDataObjectsCount(); i++) {
- if (!getDataObjects(i).isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
+ @Override
+ public final boolean isInitialized() {
+ for (net.osmand.binary.OsmandOdb.MapData element : getDataObjectsList()) {
+ if (!element.isInitialized()) return false;
}
- memoizedIsInitialized = 1;
return true;
}
- public void writeTo(com.google.protobuf.CodedOutputStream output)
+ @Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
- output.writeUInt64(10, baseId_);
+ if (hasBaseId()) {
+ output.writeUInt64(10, getBaseId());
}
- for (int i = 0; i < dataObjects_.size(); i++) {
- output.writeMessage(12, dataObjects_.get(i));
+ for (net.osmand.binary.OsmandOdb.MapData element : getDataObjectsList()) {
+ output.writeMessage(12, element);
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
- output.writeMessage(15, stringTable_);
+ if (hasStringTable()) {
+ output.writeMessage(15, getStringTable());
}
getUnknownFields().writeTo(output);
}
private int memoizedSerializedSize = -1;
- public int getSerializedSize() {
+ @Override
+ public int getSerializedSize() {
int size = memoizedSerializedSize;
if (size != -1) return size;
size = 0;
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ if (hasBaseId()) {
size += com.google.protobuf.CodedOutputStream
- .computeUInt64Size(10, baseId_);
+ .computeUInt64Size(10, getBaseId());
}
- for (int i = 0; i < dataObjects_.size(); i++) {
+ for (net.osmand.binary.OsmandOdb.MapData element : getDataObjectsList()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(12, dataObjects_.get(i));
+ .computeMessageSize(12, element);
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
+ if (hasStringTable()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(15, stringTable_);
+ .computeMessageSize(15, getStringTable());
}
size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size;
return size;
}
- private static final long serialVersionUID = 0L;
- @java.lang.Override
- protected java.lang.Object writeReplace()
- throws java.io.ObjectStreamException {
- return super.writeReplace();
- }
-
public static net.osmand.binary.OsmandOdb.MapDataBlock parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
@@ -7937,131 +4798,96 @@ public final class OsmandOdb {
}
public static Builder newBuilder() { return Builder.create(); }
- public Builder newBuilderForType() { return newBuilder(); }
+ @Override
+ public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder(net.osmand.binary.OsmandOdb.MapDataBlock prototype) {
return newBuilder().mergeFrom(prototype);
}
- public Builder toBuilder() { return newBuilder(this); }
+ @Override
+ public Builder toBuilder() { return newBuilder(this); }
- @java.lang.Override
- protected Builder newBuilderForType(
- com.google.protobuf.GeneratedMessage.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
public static final class Builder extends
- com.google.protobuf.GeneratedMessage.Builder
- implements net.osmand.binary.OsmandOdb.MapDataBlockOrBuilder {
- public static final com.google.protobuf.Descriptors.Descriptor
- getDescriptor() {
- return net.osmand.binary.OsmandOdb.internal_static_MapDataBlock_descriptor;
- }
-
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
- internalGetFieldAccessorTable() {
- return net.osmand.binary.OsmandOdb.internal_static_MapDataBlock_fieldAccessorTable;
- }
+ com.google.protobuf.GeneratedMessage.Builder {
+ private net.osmand.binary.OsmandOdb.MapDataBlock result;
// Construct using net.osmand.binary.OsmandOdb.MapDataBlock.newBuilder()
- private Builder() {
- maybeForceBuilderInitialization();
- }
+ private Builder() {}
- private Builder(BuilderParent parent) {
- super(parent);
- maybeForceBuilderInitialization();
- }
- private void maybeForceBuilderInitialization() {
- if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
- getDataObjectsFieldBuilder();
- getStringTableFieldBuilder();
- }
- }
private static Builder create() {
- return new Builder();
+ Builder builder = new Builder();
+ builder.result = new net.osmand.binary.OsmandOdb.MapDataBlock();
+ return builder;
}
- public Builder clear() {
- super.clear();
- baseId_ = 0L;
- bitField0_ = (bitField0_ & ~0x00000001);
- if (dataObjectsBuilder_ == null) {
- dataObjects_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000002);
- } else {
- dataObjectsBuilder_.clear();
+ @Override
+ protected net.osmand.binary.OsmandOdb.MapDataBlock internalGetResult() {
+ return result;
+ }
+
+ @Override
+ public Builder clear() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "Cannot call clear() after build().");
}
- if (stringTableBuilder_ == null) {
- stringTable_ = net.osmand.binary.OsmandOdb.StringTable.getDefaultInstance();
- } else {
- stringTableBuilder_.clear();
- }
- bitField0_ = (bitField0_ & ~0x00000004);
+ result = new net.osmand.binary.OsmandOdb.MapDataBlock();
return this;
}
- public Builder clone() {
- return create().mergeFrom(buildPartial());
+ @Override
+ public Builder clone() {
+ return create().mergeFrom(result);
}
- public com.google.protobuf.Descriptors.Descriptor
+ @Override
+ public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return net.osmand.binary.OsmandOdb.MapDataBlock.getDescriptor();
}
- public net.osmand.binary.OsmandOdb.MapDataBlock getDefaultInstanceForType() {
+ @Override
+ public net.osmand.binary.OsmandOdb.MapDataBlock getDefaultInstanceForType() {
return net.osmand.binary.OsmandOdb.MapDataBlock.getDefaultInstance();
}
- public net.osmand.binary.OsmandOdb.MapDataBlock build() {
- net.osmand.binary.OsmandOdb.MapDataBlock result = buildPartial();
- if (!result.isInitialized()) {
+ @Override
+ public boolean isInitialized() {
+ return result.isInitialized();
+ }
+ @Override
+ public net.osmand.binary.OsmandOdb.MapDataBlock build() {
+ if (result != null && !isInitialized()) {
throw newUninitializedMessageException(result);
}
- return result;
+ return buildPartial();
}
private net.osmand.binary.OsmandOdb.MapDataBlock buildParsed()
throws com.google.protobuf.InvalidProtocolBufferException {
- net.osmand.binary.OsmandOdb.MapDataBlock result = buildPartial();
- if (!result.isInitialized()) {
+ if (!isInitialized()) {
throw newUninitializedMessageException(
result).asInvalidProtocolBufferException();
}
- return result;
+ return buildPartial();
}
- public net.osmand.binary.OsmandOdb.MapDataBlock buildPartial() {
- net.osmand.binary.OsmandOdb.MapDataBlock result = new net.osmand.binary.OsmandOdb.MapDataBlock(this);
- int from_bitField0_ = bitField0_;
- int to_bitField0_ = 0;
- if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
- to_bitField0_ |= 0x00000001;
+ @Override
+ public net.osmand.binary.OsmandOdb.MapDataBlock buildPartial() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "build() has already been called on this Builder.");
}
- result.baseId_ = baseId_;
- if (dataObjectsBuilder_ == null) {
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
- dataObjects_ = java.util.Collections.unmodifiableList(dataObjects_);
- bitField0_ = (bitField0_ & ~0x00000002);
- }
- result.dataObjects_ = dataObjects_;
- } else {
- result.dataObjects_ = dataObjectsBuilder_.build();
+ if (result.dataObjects_ != java.util.Collections.EMPTY_LIST) {
+ result.dataObjects_ =
+ java.util.Collections.unmodifiableList(result.dataObjects_);
}
- if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
- to_bitField0_ |= 0x00000002;
- }
- if (stringTableBuilder_ == null) {
- result.stringTable_ = stringTable_;
- } else {
- result.stringTable_ = stringTableBuilder_.build();
- }
- result.bitField0_ = to_bitField0_;
- onBuilt();
- return result;
+ net.osmand.binary.OsmandOdb.MapDataBlock returnMe = result;
+ result = null;
+ return returnMe;
}
- public Builder mergeFrom(com.google.protobuf.Message other) {
+ @Override
+ public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof net.osmand.binary.OsmandOdb.MapDataBlock) {
return mergeFrom((net.osmand.binary.OsmandOdb.MapDataBlock)other);
} else {
@@ -8075,31 +4901,11 @@ public final class OsmandOdb {
if (other.hasBaseId()) {
setBaseId(other.getBaseId());
}
- if (dataObjectsBuilder_ == null) {
- if (!other.dataObjects_.isEmpty()) {
- if (dataObjects_.isEmpty()) {
- dataObjects_ = other.dataObjects_;
- bitField0_ = (bitField0_ & ~0x00000002);
- } else {
- ensureDataObjectsIsMutable();
- dataObjects_.addAll(other.dataObjects_);
- }
- onChanged();
- }
- } else {
- if (!other.dataObjects_.isEmpty()) {
- if (dataObjectsBuilder_.isEmpty()) {
- dataObjectsBuilder_.dispose();
- dataObjectsBuilder_ = null;
- dataObjects_ = other.dataObjects_;
- bitField0_ = (bitField0_ & ~0x00000002);
- dataObjectsBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getDataObjectsFieldBuilder() : null;
- } else {
- dataObjectsBuilder_.addAllMessages(other.dataObjects_);
- }
+ if (!other.dataObjects_.isEmpty()) {
+ if (result.dataObjects_.isEmpty()) {
+ result.dataObjects_ = new java.util.ArrayList();
}
+ result.dataObjects_.addAll(other.dataObjects_);
}
if (other.hasStringTable()) {
mergeStringTable(other.getStringTable());
@@ -8108,17 +4914,8 @@ public final class OsmandOdb {
return this;
}
- public final boolean isInitialized() {
- for (int i = 0; i < getDataObjectsCount(); i++) {
- if (!getDataObjects(i).isInitialized()) {
-
- return false;
- }
- }
- return true;
- }
-
- public Builder mergeFrom(
+ @Override
+ public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
@@ -8130,20 +4927,17 @@ public final class OsmandOdb {
switch (tag) {
case 0:
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
default: {
if (!parseUnknownField(input, unknownFields,
extensionRegistry, tag)) {
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
}
break;
}
case 80: {
- bitField0_ |= 0x00000001;
- baseId_ = input.readUInt64();
+ setBaseId(input.readUInt64());
break;
}
case 98: {
@@ -8165,358 +4959,130 @@ public final class OsmandOdb {
}
}
- private int bitField0_;
// optional uint64 baseId = 10;
- private long baseId_ ;
public boolean hasBaseId() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
+ return result.hasBaseId();
}
public long getBaseId() {
- return baseId_;
+ return result.getBaseId();
}
public Builder setBaseId(long value) {
- bitField0_ |= 0x00000001;
- baseId_ = value;
- onChanged();
+ result.hasBaseId = true;
+ result.baseId_ = value;
return this;
}
public Builder clearBaseId() {
- bitField0_ = (bitField0_ & ~0x00000001);
- baseId_ = 0L;
- onChanged();
+ result.hasBaseId = false;
+ result.baseId_ = 0L;
return this;
}
// repeated .MapData dataObjects = 12;
- private java.util.List dataObjects_ =
- java.util.Collections.emptyList();
- private void ensureDataObjectsIsMutable() {
- if (!((bitField0_ & 0x00000002) == 0x00000002)) {
- dataObjects_ = new java.util.ArrayList(dataObjects_);
- bitField0_ |= 0x00000002;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.MapData, net.osmand.binary.OsmandOdb.MapData.Builder, net.osmand.binary.OsmandOdb.MapDataOrBuilder> dataObjectsBuilder_;
-
public java.util.List getDataObjectsList() {
- if (dataObjectsBuilder_ == null) {
- return java.util.Collections.unmodifiableList(dataObjects_);
- } else {
- return dataObjectsBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.dataObjects_);
}
public int getDataObjectsCount() {
- if (dataObjectsBuilder_ == null) {
- return dataObjects_.size();
- } else {
- return dataObjectsBuilder_.getCount();
- }
+ return result.getDataObjectsCount();
}
public net.osmand.binary.OsmandOdb.MapData getDataObjects(int index) {
- if (dataObjectsBuilder_ == null) {
- return dataObjects_.get(index);
- } else {
- return dataObjectsBuilder_.getMessage(index);
- }
+ return result.getDataObjects(index);
}
- public Builder setDataObjects(
- int index, net.osmand.binary.OsmandOdb.MapData value) {
- if (dataObjectsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureDataObjectsIsMutable();
- dataObjects_.set(index, value);
- onChanged();
- } else {
- dataObjectsBuilder_.setMessage(index, value);
+ public Builder setDataObjects(int index, net.osmand.binary.OsmandOdb.MapData value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.dataObjects_.set(index, value);
return this;
}
- public Builder setDataObjects(
- int index, net.osmand.binary.OsmandOdb.MapData.Builder builderForValue) {
- if (dataObjectsBuilder_ == null) {
- ensureDataObjectsIsMutable();
- dataObjects_.set(index, builderForValue.build());
- onChanged();
- } else {
- dataObjectsBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setDataObjects(int index, net.osmand.binary.OsmandOdb.MapData.Builder builderForValue) {
+ result.dataObjects_.set(index, builderForValue.build());
return this;
}
public Builder addDataObjects(net.osmand.binary.OsmandOdb.MapData value) {
- if (dataObjectsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureDataObjectsIsMutable();
- dataObjects_.add(value);
- onChanged();
- } else {
- dataObjectsBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.dataObjects_.isEmpty()) {
+ result.dataObjects_ = new java.util.ArrayList();
+ }
+ result.dataObjects_.add(value);
return this;
}
- public Builder addDataObjects(
- int index, net.osmand.binary.OsmandOdb.MapData value) {
- if (dataObjectsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureDataObjectsIsMutable();
- dataObjects_.add(index, value);
- onChanged();
- } else {
- dataObjectsBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addDataObjects(
- net.osmand.binary.OsmandOdb.MapData.Builder builderForValue) {
- if (dataObjectsBuilder_ == null) {
- ensureDataObjectsIsMutable();
- dataObjects_.add(builderForValue.build());
- onChanged();
- } else {
- dataObjectsBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addDataObjects(
- int index, net.osmand.binary.OsmandOdb.MapData.Builder builderForValue) {
- if (dataObjectsBuilder_ == null) {
- ensureDataObjectsIsMutable();
- dataObjects_.add(index, builderForValue.build());
- onChanged();
- } else {
- dataObjectsBuilder_.addMessage(index, builderForValue.build());
+ public Builder addDataObjects(net.osmand.binary.OsmandOdb.MapData.Builder builderForValue) {
+ if (result.dataObjects_.isEmpty()) {
+ result.dataObjects_ = new java.util.ArrayList();
}
+ result.dataObjects_.add(builderForValue.build());
return this;
}
public Builder addAllDataObjects(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.MapData> values) {
- if (dataObjectsBuilder_ == null) {
- ensureDataObjectsIsMutable();
- super.addAll(values, dataObjects_);
- onChanged();
- } else {
- dataObjectsBuilder_.addAllMessages(values);
+ if (result.dataObjects_.isEmpty()) {
+ result.dataObjects_ = new java.util.ArrayList();
}
+ super.addAll(values, result.dataObjects_);
return this;
}
public Builder clearDataObjects() {
- if (dataObjectsBuilder_ == null) {
- dataObjects_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000002);
- onChanged();
- } else {
- dataObjectsBuilder_.clear();
- }
+ result.dataObjects_ = java.util.Collections.emptyList();
return this;
}
- public Builder removeDataObjects(int index) {
- if (dataObjectsBuilder_ == null) {
- ensureDataObjectsIsMutable();
- dataObjects_.remove(index);
- onChanged();
- } else {
- dataObjectsBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.MapData.Builder getDataObjectsBuilder(
- int index) {
- return getDataObjectsFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.MapDataOrBuilder getDataObjectsOrBuilder(
- int index) {
- if (dataObjectsBuilder_ == null) {
- return dataObjects_.get(index); } else {
- return dataObjectsBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.MapDataOrBuilder>
- getDataObjectsOrBuilderList() {
- if (dataObjectsBuilder_ != null) {
- return dataObjectsBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(dataObjects_);
- }
- }
- public net.osmand.binary.OsmandOdb.MapData.Builder addDataObjectsBuilder() {
- return getDataObjectsFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.MapData.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.MapData.Builder addDataObjectsBuilder(
- int index) {
- return getDataObjectsFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.MapData.getDefaultInstance());
- }
- public java.util.List
- getDataObjectsBuilderList() {
- return getDataObjectsFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.MapData, net.osmand.binary.OsmandOdb.MapData.Builder, net.osmand.binary.OsmandOdb.MapDataOrBuilder>
- getDataObjectsFieldBuilder() {
- if (dataObjectsBuilder_ == null) {
- dataObjectsBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.MapData, net.osmand.binary.OsmandOdb.MapData.Builder, net.osmand.binary.OsmandOdb.MapDataOrBuilder>(
- dataObjects_,
- ((bitField0_ & 0x00000002) == 0x00000002),
- getParentForChildren(),
- isClean());
- dataObjects_ = null;
- }
- return dataObjectsBuilder_;
- }
// optional .StringTable stringTable = 15;
- private net.osmand.binary.OsmandOdb.StringTable stringTable_ = net.osmand.binary.OsmandOdb.StringTable.getDefaultInstance();
- private com.google.protobuf.SingleFieldBuilder<
- net.osmand.binary.OsmandOdb.StringTable, net.osmand.binary.OsmandOdb.StringTable.Builder, net.osmand.binary.OsmandOdb.StringTableOrBuilder> stringTableBuilder_;
public boolean hasStringTable() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
+ return result.hasStringTable();
}
public net.osmand.binary.OsmandOdb.StringTable getStringTable() {
- if (stringTableBuilder_ == null) {
- return stringTable_;
- } else {
- return stringTableBuilder_.getMessage();
- }
+ return result.getStringTable();
}
public Builder setStringTable(net.osmand.binary.OsmandOdb.StringTable value) {
- if (stringTableBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- stringTable_ = value;
- onChanged();
- } else {
- stringTableBuilder_.setMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
- bitField0_ |= 0x00000004;
+ result.hasStringTable = true;
+ result.stringTable_ = value;
return this;
}
- public Builder setStringTable(
- net.osmand.binary.OsmandOdb.StringTable.Builder builderForValue) {
- if (stringTableBuilder_ == null) {
- stringTable_ = builderForValue.build();
- onChanged();
- } else {
- stringTableBuilder_.setMessage(builderForValue.build());
- }
- bitField0_ |= 0x00000004;
+ public Builder setStringTable(net.osmand.binary.OsmandOdb.StringTable.Builder builderForValue) {
+ result.hasStringTable = true;
+ result.stringTable_ = builderForValue.build();
return this;
}
public Builder mergeStringTable(net.osmand.binary.OsmandOdb.StringTable value) {
- if (stringTableBuilder_ == null) {
- if (((bitField0_ & 0x00000004) == 0x00000004) &&
- stringTable_ != net.osmand.binary.OsmandOdb.StringTable.getDefaultInstance()) {
- stringTable_ =
- net.osmand.binary.OsmandOdb.StringTable.newBuilder(stringTable_).mergeFrom(value).buildPartial();
- } else {
- stringTable_ = value;
- }
- onChanged();
+ if (result.hasStringTable() &&
+ result.stringTable_ != net.osmand.binary.OsmandOdb.StringTable.getDefaultInstance()) {
+ result.stringTable_ =
+ net.osmand.binary.OsmandOdb.StringTable.newBuilder(result.stringTable_).mergeFrom(value).buildPartial();
} else {
- stringTableBuilder_.mergeFrom(value);
+ result.stringTable_ = value;
}
- bitField0_ |= 0x00000004;
+ result.hasStringTable = true;
return this;
}
public Builder clearStringTable() {
- if (stringTableBuilder_ == null) {
- stringTable_ = net.osmand.binary.OsmandOdb.StringTable.getDefaultInstance();
- onChanged();
- } else {
- stringTableBuilder_.clear();
- }
- bitField0_ = (bitField0_ & ~0x00000004);
+ result.hasStringTable = false;
+ result.stringTable_ = net.osmand.binary.OsmandOdb.StringTable.getDefaultInstance();
return this;
}
- public net.osmand.binary.OsmandOdb.StringTable.Builder getStringTableBuilder() {
- bitField0_ |= 0x00000004;
- onChanged();
- return getStringTableFieldBuilder().getBuilder();
- }
- public net.osmand.binary.OsmandOdb.StringTableOrBuilder getStringTableOrBuilder() {
- if (stringTableBuilder_ != null) {
- return stringTableBuilder_.getMessageOrBuilder();
- } else {
- return stringTable_;
- }
- }
- private com.google.protobuf.SingleFieldBuilder<
- net.osmand.binary.OsmandOdb.StringTable, net.osmand.binary.OsmandOdb.StringTable.Builder, net.osmand.binary.OsmandOdb.StringTableOrBuilder>
- getStringTableFieldBuilder() {
- if (stringTableBuilder_ == null) {
- stringTableBuilder_ = new com.google.protobuf.SingleFieldBuilder<
- net.osmand.binary.OsmandOdb.StringTable, net.osmand.binary.OsmandOdb.StringTable.Builder, net.osmand.binary.OsmandOdb.StringTableOrBuilder>(
- stringTable_,
- getParentForChildren(),
- isClean());
- stringTable_ = null;
- }
- return stringTableBuilder_;
- }
// @@protoc_insertion_point(builder_scope:MapDataBlock)
}
static {
defaultInstance = new MapDataBlock(true);
+ net.osmand.binary.OsmandOdb.internalForceInit();
defaultInstance.initFields();
}
// @@protoc_insertion_point(class_scope:MapDataBlock)
}
- public interface MapDataOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // optional bytes pointCoordinates = 1;
- boolean hasPointCoordinates();
- com.google.protobuf.ByteString getPointCoordinates();
-
- // optional bytes lineCoordinates = 2;
- boolean hasLineCoordinates();
- com.google.protobuf.ByteString getLineCoordinates();
-
- // optional bytes polygonOuterCoordinates = 3;
- boolean hasPolygonOuterCoordinates();
- com.google.protobuf.ByteString getPolygonOuterCoordinates();
-
- // repeated bytes polygonInnerCoordinates = 4;
- java.util.List getPolygonInnerCoordinatesList();
- int getPolygonInnerCoordinatesCount();
- com.google.protobuf.ByteString getPolygonInnerCoordinates(int index);
-
- // optional bytes additionalTypes = 6;
- boolean hasAdditionalTypes();
- com.google.protobuf.ByteString getAdditionalTypes();
-
- // required bytes types = 7;
- boolean hasTypes();
- com.google.protobuf.ByteString getTypes();
-
- // optional bytes stringNames = 10;
- boolean hasStringNames();
- com.google.protobuf.ByteString getStringNames();
-
- // required sint64 id = 12;
- boolean hasId();
- long getId();
- }
public static final class MapData extends
- com.google.protobuf.GeneratedMessage
- implements MapDataOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use MapData.newBuilder() to construct.
- private MapData(Builder builder) {
- super(builder);
+ private MapData() {
+ initFields();
}
private MapData(boolean noInit) {}
@@ -8525,7 +5091,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public MapData getDefaultInstanceForType() {
+ @Override
+ public MapData getDefaultInstanceForType() {
return defaultInstance;
}
@@ -8534,208 +5101,148 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_MapData_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_MapData_fieldAccessorTable;
}
- private int bitField0_;
- // optional bytes pointCoordinates = 1;
- public static final int POINTCOORDINATES_FIELD_NUMBER = 1;
- private com.google.protobuf.ByteString pointCoordinates_;
- public boolean hasPointCoordinates() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
- }
- public com.google.protobuf.ByteString getPointCoordinates() {
- return pointCoordinates_;
- }
+ // optional bytes coordinates = 1;
+ public static final int COORDINATES_FIELD_NUMBER = 1;
+ private boolean hasCoordinates;
+ private com.google.protobuf.ByteString coordinates_ = com.google.protobuf.ByteString.EMPTY;
+ public boolean hasCoordinates() { return hasCoordinates; }
+ public com.google.protobuf.ByteString getCoordinates() { return coordinates_; }
- // optional bytes lineCoordinates = 2;
- public static final int LINECOORDINATES_FIELD_NUMBER = 2;
- private com.google.protobuf.ByteString lineCoordinates_;
- public boolean hasLineCoordinates() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
- }
- public com.google.protobuf.ByteString getLineCoordinates() {
- return lineCoordinates_;
- }
-
- // optional bytes polygonOuterCoordinates = 3;
- public static final int POLYGONOUTERCOORDINATES_FIELD_NUMBER = 3;
- private com.google.protobuf.ByteString polygonOuterCoordinates_;
- public boolean hasPolygonOuterCoordinates() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
- }
- public com.google.protobuf.ByteString getPolygonOuterCoordinates() {
- return polygonOuterCoordinates_;
- }
+ // optional bytes areaCoordinates = 2;
+ public static final int AREACOORDINATES_FIELD_NUMBER = 2;
+ private boolean hasAreaCoordinates;
+ private com.google.protobuf.ByteString areaCoordinates_ = com.google.protobuf.ByteString.EMPTY;
+ public boolean hasAreaCoordinates() { return hasAreaCoordinates; }
+ public com.google.protobuf.ByteString getAreaCoordinates() { return areaCoordinates_; }
// repeated bytes polygonInnerCoordinates = 4;
public static final int POLYGONINNERCOORDINATES_FIELD_NUMBER = 4;
- private java.util.List polygonInnerCoordinates_;
- public java.util.List
- getPolygonInnerCoordinatesList() {
+ private java.util.List polygonInnerCoordinates_ =
+ java.util.Collections.emptyList();
+ public java.util.List getPolygonInnerCoordinatesList() {
return polygonInnerCoordinates_;
}
- public int getPolygonInnerCoordinatesCount() {
- return polygonInnerCoordinates_.size();
- }
+ public int getPolygonInnerCoordinatesCount() { return polygonInnerCoordinates_.size(); }
public com.google.protobuf.ByteString getPolygonInnerCoordinates(int index) {
return polygonInnerCoordinates_.get(index);
}
// optional bytes additionalTypes = 6;
public static final int ADDITIONALTYPES_FIELD_NUMBER = 6;
- private com.google.protobuf.ByteString additionalTypes_;
- public boolean hasAdditionalTypes() {
- return ((bitField0_ & 0x00000008) == 0x00000008);
- }
- public com.google.protobuf.ByteString getAdditionalTypes() {
- return additionalTypes_;
- }
+ private boolean hasAdditionalTypes;
+ private com.google.protobuf.ByteString additionalTypes_ = com.google.protobuf.ByteString.EMPTY;
+ public boolean hasAdditionalTypes() { return hasAdditionalTypes; }
+ public com.google.protobuf.ByteString getAdditionalTypes() { return additionalTypes_; }
// required bytes types = 7;
public static final int TYPES_FIELD_NUMBER = 7;
- private com.google.protobuf.ByteString types_;
- public boolean hasTypes() {
- return ((bitField0_ & 0x00000010) == 0x00000010);
- }
- public com.google.protobuf.ByteString getTypes() {
- return types_;
- }
+ private boolean hasTypes;
+ private com.google.protobuf.ByteString types_ = com.google.protobuf.ByteString.EMPTY;
+ public boolean hasTypes() { return hasTypes; }
+ public com.google.protobuf.ByteString getTypes() { return types_; }
// optional bytes stringNames = 10;
public static final int STRINGNAMES_FIELD_NUMBER = 10;
- private com.google.protobuf.ByteString stringNames_;
- public boolean hasStringNames() {
- return ((bitField0_ & 0x00000020) == 0x00000020);
- }
- public com.google.protobuf.ByteString getStringNames() {
- return stringNames_;
- }
+ private boolean hasStringNames;
+ private com.google.protobuf.ByteString stringNames_ = com.google.protobuf.ByteString.EMPTY;
+ public boolean hasStringNames() { return hasStringNames; }
+ public com.google.protobuf.ByteString getStringNames() { return stringNames_; }
// required sint64 id = 12;
public static final int ID_FIELD_NUMBER = 12;
- private long id_;
- public boolean hasId() {
- return ((bitField0_ & 0x00000040) == 0x00000040);
- }
- public long getId() {
- return id_;
- }
+ private boolean hasId;
+ private long id_ = 0L;
+ public boolean hasId() { return hasId; }
+ public long getId() { return id_; }
private void initFields() {
- pointCoordinates_ = com.google.protobuf.ByteString.EMPTY;
- lineCoordinates_ = com.google.protobuf.ByteString.EMPTY;
- polygonOuterCoordinates_ = com.google.protobuf.ByteString.EMPTY;
- polygonInnerCoordinates_ = java.util.Collections.emptyList();;
- additionalTypes_ = com.google.protobuf.ByteString.EMPTY;
- types_ = com.google.protobuf.ByteString.EMPTY;
- stringNames_ = com.google.protobuf.ByteString.EMPTY;
- id_ = 0L;
}
- private byte memoizedIsInitialized = -1;
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized != -1) return isInitialized == 1;
-
- if (!hasTypes()) {
- memoizedIsInitialized = 0;
- return false;
- }
- if (!hasId()) {
- memoizedIsInitialized = 0;
- return false;
- }
- memoizedIsInitialized = 1;
+ @Override
+ public final boolean isInitialized() {
+ if (!hasTypes) return false;
+ if (!hasId) return false;
return true;
}
- public void writeTo(com.google.protobuf.CodedOutputStream output)
+ @Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
- output.writeBytes(1, pointCoordinates_);
+ if (hasCoordinates()) {
+ output.writeBytes(1, getCoordinates());
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
- output.writeBytes(2, lineCoordinates_);
+ if (hasAreaCoordinates()) {
+ output.writeBytes(2, getAreaCoordinates());
}
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
- output.writeBytes(3, polygonOuterCoordinates_);
+ for (com.google.protobuf.ByteString element : getPolygonInnerCoordinatesList()) {
+ output.writeBytes(4, element);
}
- for (int i = 0; i < polygonInnerCoordinates_.size(); i++) {
- output.writeBytes(4, polygonInnerCoordinates_.get(i));
+ if (hasAdditionalTypes()) {
+ output.writeBytes(6, getAdditionalTypes());
}
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
- output.writeBytes(6, additionalTypes_);
+ if (hasTypes()) {
+ output.writeBytes(7, getTypes());
}
- if (((bitField0_ & 0x00000010) == 0x00000010)) {
- output.writeBytes(7, types_);
+ if (hasStringNames()) {
+ output.writeBytes(10, getStringNames());
}
- if (((bitField0_ & 0x00000020) == 0x00000020)) {
- output.writeBytes(10, stringNames_);
- }
- if (((bitField0_ & 0x00000040) == 0x00000040)) {
- output.writeSInt64(12, id_);
+ if (hasId()) {
+ output.writeSInt64(12, getId());
}
getUnknownFields().writeTo(output);
}
private int memoizedSerializedSize = -1;
- public int getSerializedSize() {
+ @Override
+ public int getSerializedSize() {
int size = memoizedSerializedSize;
if (size != -1) return size;
size = 0;
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ if (hasCoordinates()) {
size += com.google.protobuf.CodedOutputStream
- .computeBytesSize(1, pointCoordinates_);
+ .computeBytesSize(1, getCoordinates());
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
+ if (hasAreaCoordinates()) {
size += com.google.protobuf.CodedOutputStream
- .computeBytesSize(2, lineCoordinates_);
- }
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
- size += com.google.protobuf.CodedOutputStream
- .computeBytesSize(3, polygonOuterCoordinates_);
+ .computeBytesSize(2, getAreaCoordinates());
}
{
int dataSize = 0;
- for (int i = 0; i < polygonInnerCoordinates_.size(); i++) {
+ for (com.google.protobuf.ByteString element : getPolygonInnerCoordinatesList()) {
dataSize += com.google.protobuf.CodedOutputStream
- .computeBytesSizeNoTag(polygonInnerCoordinates_.get(i));
+ .computeBytesSizeNoTag(element);
}
size += dataSize;
size += 1 * getPolygonInnerCoordinatesList().size();
}
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
+ if (hasAdditionalTypes()) {
size += com.google.protobuf.CodedOutputStream
- .computeBytesSize(6, additionalTypes_);
+ .computeBytesSize(6, getAdditionalTypes());
}
- if (((bitField0_ & 0x00000010) == 0x00000010)) {
+ if (hasTypes()) {
size += com.google.protobuf.CodedOutputStream
- .computeBytesSize(7, types_);
+ .computeBytesSize(7, getTypes());
}
- if (((bitField0_ & 0x00000020) == 0x00000020)) {
+ if (hasStringNames()) {
size += com.google.protobuf.CodedOutputStream
- .computeBytesSize(10, stringNames_);
+ .computeBytesSize(10, getStringNames());
}
- if (((bitField0_ & 0x00000040) == 0x00000040)) {
+ if (hasId()) {
size += com.google.protobuf.CodedOutputStream
- .computeSInt64Size(12, id_);
+ .computeSInt64Size(12, getId());
}
size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size;
return size;
}
- private static final long serialVersionUID = 0L;
- @java.lang.Override
- protected java.lang.Object writeReplace()
- throws java.io.ObjectStreamException {
- return super.writeReplace();
- }
-
public static net.osmand.binary.OsmandOdb.MapData parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
@@ -8804,143 +5311,96 @@ public final class OsmandOdb {
}
public static Builder newBuilder() { return Builder.create(); }
- public Builder newBuilderForType() { return newBuilder(); }
+ @Override
+ public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder(net.osmand.binary.OsmandOdb.MapData prototype) {
return newBuilder().mergeFrom(prototype);
}
- public Builder toBuilder() { return newBuilder(this); }
+ @Override
+ public Builder toBuilder() { return newBuilder(this); }
- @java.lang.Override
- protected Builder newBuilderForType(
- com.google.protobuf.GeneratedMessage.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
public static final class Builder extends
- com.google.protobuf.GeneratedMessage.Builder
- implements net.osmand.binary.OsmandOdb.MapDataOrBuilder {
- public static final com.google.protobuf.Descriptors.Descriptor
- getDescriptor() {
- return net.osmand.binary.OsmandOdb.internal_static_MapData_descriptor;
- }
-
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
- internalGetFieldAccessorTable() {
- return net.osmand.binary.OsmandOdb.internal_static_MapData_fieldAccessorTable;
- }
+ com.google.protobuf.GeneratedMessage.Builder {
+ private net.osmand.binary.OsmandOdb.MapData result;
// Construct using net.osmand.binary.OsmandOdb.MapData.newBuilder()
- private Builder() {
- maybeForceBuilderInitialization();
- }
+ private Builder() {}
- private Builder(BuilderParent parent) {
- super(parent);
- maybeForceBuilderInitialization();
- }
- private void maybeForceBuilderInitialization() {
- if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
- }
- }
private static Builder create() {
- return new Builder();
+ Builder builder = new Builder();
+ builder.result = new net.osmand.binary.OsmandOdb.MapData();
+ return builder;
}
- public Builder clear() {
- super.clear();
- pointCoordinates_ = com.google.protobuf.ByteString.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000001);
- lineCoordinates_ = com.google.protobuf.ByteString.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000002);
- polygonOuterCoordinates_ = com.google.protobuf.ByteString.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000004);
- polygonInnerCoordinates_ = java.util.Collections.emptyList();;
- bitField0_ = (bitField0_ & ~0x00000008);
- additionalTypes_ = com.google.protobuf.ByteString.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000010);
- types_ = com.google.protobuf.ByteString.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000020);
- stringNames_ = com.google.protobuf.ByteString.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000040);
- id_ = 0L;
- bitField0_ = (bitField0_ & ~0x00000080);
+ @Override
+ protected net.osmand.binary.OsmandOdb.MapData internalGetResult() {
+ return result;
+ }
+
+ @Override
+ public Builder clear() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "Cannot call clear() after build().");
+ }
+ result = new net.osmand.binary.OsmandOdb.MapData();
return this;
}
- public Builder clone() {
- return create().mergeFrom(buildPartial());
+ @Override
+ public Builder clone() {
+ return create().mergeFrom(result);
}
- public com.google.protobuf.Descriptors.Descriptor
+ @Override
+ public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return net.osmand.binary.OsmandOdb.MapData.getDescriptor();
}
- public net.osmand.binary.OsmandOdb.MapData getDefaultInstanceForType() {
+ @Override
+ public net.osmand.binary.OsmandOdb.MapData getDefaultInstanceForType() {
return net.osmand.binary.OsmandOdb.MapData.getDefaultInstance();
}
- public net.osmand.binary.OsmandOdb.MapData build() {
- net.osmand.binary.OsmandOdb.MapData result = buildPartial();
- if (!result.isInitialized()) {
+ @Override
+ public boolean isInitialized() {
+ return result.isInitialized();
+ }
+ @Override
+ public net.osmand.binary.OsmandOdb.MapData build() {
+ if (result != null && !isInitialized()) {
throw newUninitializedMessageException(result);
}
- return result;
+ return buildPartial();
}
private net.osmand.binary.OsmandOdb.MapData buildParsed()
throws com.google.protobuf.InvalidProtocolBufferException {
- net.osmand.binary.OsmandOdb.MapData result = buildPartial();
- if (!result.isInitialized()) {
+ if (!isInitialized()) {
throw newUninitializedMessageException(
result).asInvalidProtocolBufferException();
}
- return result;
+ return buildPartial();
}
- public net.osmand.binary.OsmandOdb.MapData buildPartial() {
- net.osmand.binary.OsmandOdb.MapData result = new net.osmand.binary.OsmandOdb.MapData(this);
- int from_bitField0_ = bitField0_;
- int to_bitField0_ = 0;
- if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
- to_bitField0_ |= 0x00000001;
+ @Override
+ public net.osmand.binary.OsmandOdb.MapData buildPartial() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "build() has already been called on this Builder.");
}
- result.pointCoordinates_ = pointCoordinates_;
- if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
- to_bitField0_ |= 0x00000002;
+ if (result.polygonInnerCoordinates_ != java.util.Collections.EMPTY_LIST) {
+ result.polygonInnerCoordinates_ =
+ java.util.Collections.unmodifiableList(result.polygonInnerCoordinates_);
}
- result.lineCoordinates_ = lineCoordinates_;
- if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
- to_bitField0_ |= 0x00000004;
- }
- result.polygonOuterCoordinates_ = polygonOuterCoordinates_;
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
- polygonInnerCoordinates_ = java.util.Collections.unmodifiableList(polygonInnerCoordinates_);
- bitField0_ = (bitField0_ & ~0x00000008);
- }
- result.polygonInnerCoordinates_ = polygonInnerCoordinates_;
- if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
- to_bitField0_ |= 0x00000008;
- }
- result.additionalTypes_ = additionalTypes_;
- if (((from_bitField0_ & 0x00000020) == 0x00000020)) {
- to_bitField0_ |= 0x00000010;
- }
- result.types_ = types_;
- if (((from_bitField0_ & 0x00000040) == 0x00000040)) {
- to_bitField0_ |= 0x00000020;
- }
- result.stringNames_ = stringNames_;
- if (((from_bitField0_ & 0x00000080) == 0x00000080)) {
- to_bitField0_ |= 0x00000040;
- }
- result.id_ = id_;
- result.bitField0_ = to_bitField0_;
- onBuilt();
- return result;
+ net.osmand.binary.OsmandOdb.MapData returnMe = result;
+ result = null;
+ return returnMe;
}
- public Builder mergeFrom(com.google.protobuf.Message other) {
+ @Override
+ public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof net.osmand.binary.OsmandOdb.MapData) {
return mergeFrom((net.osmand.binary.OsmandOdb.MapData)other);
} else {
@@ -8951,24 +5411,17 @@ public final class OsmandOdb {
public Builder mergeFrom(net.osmand.binary.OsmandOdb.MapData other) {
if (other == net.osmand.binary.OsmandOdb.MapData.getDefaultInstance()) return this;
- if (other.hasPointCoordinates()) {
- setPointCoordinates(other.getPointCoordinates());
+ if (other.hasCoordinates()) {
+ setCoordinates(other.getCoordinates());
}
- if (other.hasLineCoordinates()) {
- setLineCoordinates(other.getLineCoordinates());
- }
- if (other.hasPolygonOuterCoordinates()) {
- setPolygonOuterCoordinates(other.getPolygonOuterCoordinates());
+ if (other.hasAreaCoordinates()) {
+ setAreaCoordinates(other.getAreaCoordinates());
}
if (!other.polygonInnerCoordinates_.isEmpty()) {
- if (polygonInnerCoordinates_.isEmpty()) {
- polygonInnerCoordinates_ = other.polygonInnerCoordinates_;
- bitField0_ = (bitField0_ & ~0x00000008);
- } else {
- ensurePolygonInnerCoordinatesIsMutable();
- polygonInnerCoordinates_.addAll(other.polygonInnerCoordinates_);
+ if (result.polygonInnerCoordinates_.isEmpty()) {
+ result.polygonInnerCoordinates_ = new java.util.ArrayList();
}
- onChanged();
+ result.polygonInnerCoordinates_.addAll(other.polygonInnerCoordinates_);
}
if (other.hasAdditionalTypes()) {
setAdditionalTypes(other.getAdditionalTypes());
@@ -8986,19 +5439,8 @@ public final class OsmandOdb {
return this;
}
- public final boolean isInitialized() {
- if (!hasTypes()) {
-
- return false;
- }
- if (!hasId()) {
-
- return false;
- }
- return true;
- }
-
- public Builder mergeFrom(
+ @Override
+ public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
@@ -9010,276 +5452,208 @@ public final class OsmandOdb {
switch (tag) {
case 0:
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
default: {
if (!parseUnknownField(input, unknownFields,
extensionRegistry, tag)) {
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
}
break;
}
case 10: {
- bitField0_ |= 0x00000001;
- pointCoordinates_ = input.readBytes();
+ setCoordinates(input.readBytes());
break;
}
case 18: {
- bitField0_ |= 0x00000002;
- lineCoordinates_ = input.readBytes();
- break;
- }
- case 26: {
- bitField0_ |= 0x00000004;
- polygonOuterCoordinates_ = input.readBytes();
+ setAreaCoordinates(input.readBytes());
break;
}
case 34: {
- ensurePolygonInnerCoordinatesIsMutable();
- polygonInnerCoordinates_.add(input.readBytes());
+ addPolygonInnerCoordinates(input.readBytes());
break;
}
case 50: {
- bitField0_ |= 0x00000010;
- additionalTypes_ = input.readBytes();
+ setAdditionalTypes(input.readBytes());
break;
}
case 58: {
- bitField0_ |= 0x00000020;
- types_ = input.readBytes();
+ setTypes(input.readBytes());
break;
}
case 82: {
- bitField0_ |= 0x00000040;
- stringNames_ = input.readBytes();
+ setStringNames(input.readBytes());
break;
}
case 96: {
- bitField0_ |= 0x00000080;
- id_ = input.readSInt64();
+ setId(input.readSInt64());
break;
}
}
}
}
- private int bitField0_;
- // optional bytes pointCoordinates = 1;
- private com.google.protobuf.ByteString pointCoordinates_ = com.google.protobuf.ByteString.EMPTY;
- public boolean hasPointCoordinates() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
+ // optional bytes coordinates = 1;
+ public boolean hasCoordinates() {
+ return result.hasCoordinates();
}
- public com.google.protobuf.ByteString getPointCoordinates() {
- return pointCoordinates_;
+ public com.google.protobuf.ByteString getCoordinates() {
+ return result.getCoordinates();
}
- public Builder setPointCoordinates(com.google.protobuf.ByteString value) {
+ public Builder setCoordinates(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
- bitField0_ |= 0x00000001;
- pointCoordinates_ = value;
- onChanged();
+ result.hasCoordinates = true;
+ result.coordinates_ = value;
return this;
}
- public Builder clearPointCoordinates() {
- bitField0_ = (bitField0_ & ~0x00000001);
- pointCoordinates_ = getDefaultInstance().getPointCoordinates();
- onChanged();
+ public Builder clearCoordinates() {
+ result.hasCoordinates = false;
+ result.coordinates_ = getDefaultInstance().getCoordinates();
return this;
}
- // optional bytes lineCoordinates = 2;
- private com.google.protobuf.ByteString lineCoordinates_ = com.google.protobuf.ByteString.EMPTY;
- public boolean hasLineCoordinates() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
+ // optional bytes areaCoordinates = 2;
+ public boolean hasAreaCoordinates() {
+ return result.hasAreaCoordinates();
}
- public com.google.protobuf.ByteString getLineCoordinates() {
- return lineCoordinates_;
+ public com.google.protobuf.ByteString getAreaCoordinates() {
+ return result.getAreaCoordinates();
}
- public Builder setLineCoordinates(com.google.protobuf.ByteString value) {
+ public Builder setAreaCoordinates(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
- bitField0_ |= 0x00000002;
- lineCoordinates_ = value;
- onChanged();
+ result.hasAreaCoordinates = true;
+ result.areaCoordinates_ = value;
return this;
}
- public Builder clearLineCoordinates() {
- bitField0_ = (bitField0_ & ~0x00000002);
- lineCoordinates_ = getDefaultInstance().getLineCoordinates();
- onChanged();
- return this;
- }
-
- // optional bytes polygonOuterCoordinates = 3;
- private com.google.protobuf.ByteString polygonOuterCoordinates_ = com.google.protobuf.ByteString.EMPTY;
- public boolean hasPolygonOuterCoordinates() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
- }
- public com.google.protobuf.ByteString getPolygonOuterCoordinates() {
- return polygonOuterCoordinates_;
- }
- public Builder setPolygonOuterCoordinates(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- bitField0_ |= 0x00000004;
- polygonOuterCoordinates_ = value;
- onChanged();
- return this;
- }
- public Builder clearPolygonOuterCoordinates() {
- bitField0_ = (bitField0_ & ~0x00000004);
- polygonOuterCoordinates_ = getDefaultInstance().getPolygonOuterCoordinates();
- onChanged();
+ public Builder clearAreaCoordinates() {
+ result.hasAreaCoordinates = false;
+ result.areaCoordinates_ = getDefaultInstance().getAreaCoordinates();
return this;
}
// repeated bytes polygonInnerCoordinates = 4;
- private java.util.List polygonInnerCoordinates_ = java.util.Collections.emptyList();;
- private void ensurePolygonInnerCoordinatesIsMutable() {
- if (!((bitField0_ & 0x00000008) == 0x00000008)) {
- polygonInnerCoordinates_ = new java.util.ArrayList(polygonInnerCoordinates_);
- bitField0_ |= 0x00000008;
- }
- }
- public java.util.List
- getPolygonInnerCoordinatesList() {
- return java.util.Collections.unmodifiableList(polygonInnerCoordinates_);
+ public java.util.List getPolygonInnerCoordinatesList() {
+ return java.util.Collections.unmodifiableList(result.polygonInnerCoordinates_);
}
public int getPolygonInnerCoordinatesCount() {
- return polygonInnerCoordinates_.size();
+ return result.getPolygonInnerCoordinatesCount();
}
public com.google.protobuf.ByteString getPolygonInnerCoordinates(int index) {
- return polygonInnerCoordinates_.get(index);
+ return result.getPolygonInnerCoordinates(index);
}
- public Builder setPolygonInnerCoordinates(
- int index, com.google.protobuf.ByteString value) {
+ public Builder setPolygonInnerCoordinates(int index, com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
- ensurePolygonInnerCoordinatesIsMutable();
- polygonInnerCoordinates_.set(index, value);
- onChanged();
+ result.polygonInnerCoordinates_.set(index, value);
return this;
}
public Builder addPolygonInnerCoordinates(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
- ensurePolygonInnerCoordinatesIsMutable();
- polygonInnerCoordinates_.add(value);
- onChanged();
+ if (result.polygonInnerCoordinates_.isEmpty()) {
+ result.polygonInnerCoordinates_ = new java.util.ArrayList();
+ }
+ result.polygonInnerCoordinates_.add(value);
return this;
}
public Builder addAllPolygonInnerCoordinates(
java.lang.Iterable extends com.google.protobuf.ByteString> values) {
- ensurePolygonInnerCoordinatesIsMutable();
- super.addAll(values, polygonInnerCoordinates_);
- onChanged();
+ if (result.polygonInnerCoordinates_.isEmpty()) {
+ result.polygonInnerCoordinates_ = new java.util.ArrayList();
+ }
+ super.addAll(values, result.polygonInnerCoordinates_);
return this;
}
public Builder clearPolygonInnerCoordinates() {
- polygonInnerCoordinates_ = java.util.Collections.emptyList();;
- bitField0_ = (bitField0_ & ~0x00000008);
- onChanged();
+ result.polygonInnerCoordinates_ = java.util.Collections.emptyList();
return this;
}
// optional bytes additionalTypes = 6;
- private com.google.protobuf.ByteString additionalTypes_ = com.google.protobuf.ByteString.EMPTY;
public boolean hasAdditionalTypes() {
- return ((bitField0_ & 0x00000010) == 0x00000010);
+ return result.hasAdditionalTypes();
}
public com.google.protobuf.ByteString getAdditionalTypes() {
- return additionalTypes_;
+ return result.getAdditionalTypes();
}
public Builder setAdditionalTypes(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
- bitField0_ |= 0x00000010;
- additionalTypes_ = value;
- onChanged();
+ result.hasAdditionalTypes = true;
+ result.additionalTypes_ = value;
return this;
}
public Builder clearAdditionalTypes() {
- bitField0_ = (bitField0_ & ~0x00000010);
- additionalTypes_ = getDefaultInstance().getAdditionalTypes();
- onChanged();
+ result.hasAdditionalTypes = false;
+ result.additionalTypes_ = getDefaultInstance().getAdditionalTypes();
return this;
}
// required bytes types = 7;
- private com.google.protobuf.ByteString types_ = com.google.protobuf.ByteString.EMPTY;
public boolean hasTypes() {
- return ((bitField0_ & 0x00000020) == 0x00000020);
+ return result.hasTypes();
}
public com.google.protobuf.ByteString getTypes() {
- return types_;
+ return result.getTypes();
}
public Builder setTypes(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
- bitField0_ |= 0x00000020;
- types_ = value;
- onChanged();
+ result.hasTypes = true;
+ result.types_ = value;
return this;
}
public Builder clearTypes() {
- bitField0_ = (bitField0_ & ~0x00000020);
- types_ = getDefaultInstance().getTypes();
- onChanged();
+ result.hasTypes = false;
+ result.types_ = getDefaultInstance().getTypes();
return this;
}
// optional bytes stringNames = 10;
- private com.google.protobuf.ByteString stringNames_ = com.google.protobuf.ByteString.EMPTY;
public boolean hasStringNames() {
- return ((bitField0_ & 0x00000040) == 0x00000040);
+ return result.hasStringNames();
}
public com.google.protobuf.ByteString getStringNames() {
- return stringNames_;
+ return result.getStringNames();
}
public Builder setStringNames(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
- bitField0_ |= 0x00000040;
- stringNames_ = value;
- onChanged();
+ result.hasStringNames = true;
+ result.stringNames_ = value;
return this;
}
public Builder clearStringNames() {
- bitField0_ = (bitField0_ & ~0x00000040);
- stringNames_ = getDefaultInstance().getStringNames();
- onChanged();
+ result.hasStringNames = false;
+ result.stringNames_ = getDefaultInstance().getStringNames();
return this;
}
// required sint64 id = 12;
- private long id_ ;
public boolean hasId() {
- return ((bitField0_ & 0x00000080) == 0x00000080);
+ return result.hasId();
}
public long getId() {
- return id_;
+ return result.getId();
}
public Builder setId(long value) {
- bitField0_ |= 0x00000080;
- id_ = value;
- onChanged();
+ result.hasId = true;
+ result.id_ = value;
return this;
}
public Builder clearId() {
- bitField0_ = (bitField0_ & ~0x00000080);
- id_ = 0L;
- onChanged();
+ result.hasId = false;
+ result.id_ = 0L;
return this;
}
@@ -9288,49 +5662,18 @@ public final class OsmandOdb {
static {
defaultInstance = new MapData(true);
+ net.osmand.binary.OsmandOdb.internalForceInit();
defaultInstance.initFields();
}
// @@protoc_insertion_point(class_scope:MapData)
}
- public interface OsmAndAddressIndexOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // required string name = 1;
- boolean hasName();
- String getName();
-
- // optional string name_en = 2;
- boolean hasNameEn();
- String getNameEn();
-
- // optional .OsmAndTileBox boundaries = 3;
- boolean hasBoundaries();
- net.osmand.binary.OsmandOdb.OsmAndTileBox getBoundaries();
- net.osmand.binary.OsmandOdb.OsmAndTileBoxOrBuilder getBoundariesOrBuilder();
-
- // repeated .OsmAndAddressIndex.CitiesIndex cities = 6;
- java.util.List
- getCitiesList();
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex getCities(int index);
- int getCitiesCount();
- java.util.List extends net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndexOrBuilder>
- getCitiesOrBuilderList();
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndexOrBuilder getCitiesOrBuilder(
- int index);
-
- // optional .OsmAndAddressNameIndexData nameIndex = 7;
- boolean hasNameIndex();
- net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData getNameIndex();
- net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexDataOrBuilder getNameIndexOrBuilder();
- }
public static final class OsmAndAddressIndex extends
- com.google.protobuf.GeneratedMessage
- implements OsmAndAddressIndexOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use OsmAndAddressIndex.newBuilder() to construct.
- private OsmAndAddressIndex(Builder builder) {
- super(builder);
+ private OsmAndAddressIndex() {
+ initFields();
}
private OsmAndAddressIndex(boolean noInit) {}
@@ -9339,7 +5682,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public OsmAndAddressIndex getDefaultInstanceForType() {
+ @Override
+ public OsmAndAddressIndex getDefaultInstanceForType() {
return defaultInstance;
}
@@ -9348,44 +5692,17 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndAddressIndex_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndAddressIndex_fieldAccessorTable;
}
- public interface CitiesIndexOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // required uint32 type = 2;
- boolean hasType();
- int getType();
-
- // repeated .CityIndex cities = 5;
- java.util.List
- getCitiesList();
- net.osmand.binary.OsmandOdb.CityIndex getCities(int index);
- int getCitiesCount();
- java.util.List extends net.osmand.binary.OsmandOdb.CityIndexOrBuilder>
- getCitiesOrBuilderList();
- net.osmand.binary.OsmandOdb.CityIndexOrBuilder getCitiesOrBuilder(
- int index);
-
- // repeated .CityBlockIndex blocks = 7;
- java.util.List
- getBlocksList();
- net.osmand.binary.OsmandOdb.CityBlockIndex getBlocks(int index);
- int getBlocksCount();
- java.util.List extends net.osmand.binary.OsmandOdb.CityBlockIndexOrBuilder>
- getBlocksOrBuilderList();
- net.osmand.binary.OsmandOdb.CityBlockIndexOrBuilder getBlocksOrBuilder(
- int index);
- }
public static final class CitiesIndex extends
- com.google.protobuf.GeneratedMessage
- implements CitiesIndexOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use CitiesIndex.newBuilder() to construct.
- private CitiesIndex(Builder builder) {
- super(builder);
+ private CitiesIndex() {
+ initFields();
}
private CitiesIndex(boolean noInit) {}
@@ -9394,7 +5711,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public CitiesIndex getDefaultInstanceForType() {
+ @Override
+ public CitiesIndex getDefaultInstanceForType() {
return defaultInstance;
}
@@ -9403,139 +5721,97 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndAddressIndex_CitiesIndex_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndAddressIndex_CitiesIndex_fieldAccessorTable;
}
- private int bitField0_;
// required uint32 type = 2;
public static final int TYPE_FIELD_NUMBER = 2;
- private int type_;
- public boolean hasType() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
- }
- public int getType() {
- return type_;
- }
+ private boolean hasType;
+ private int type_ = 0;
+ public boolean hasType() { return hasType; }
+ public int getType() { return type_; }
// repeated .CityIndex cities = 5;
public static final int CITIES_FIELD_NUMBER = 5;
- private java.util.List cities_;
+ private java.util.List cities_ =
+ java.util.Collections.emptyList();
public java.util.List getCitiesList() {
return cities_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.CityIndexOrBuilder>
- getCitiesOrBuilderList() {
- return cities_;
- }
- public int getCitiesCount() {
- return cities_.size();
- }
+ public int getCitiesCount() { return cities_.size(); }
public net.osmand.binary.OsmandOdb.CityIndex getCities(int index) {
return cities_.get(index);
}
- public net.osmand.binary.OsmandOdb.CityIndexOrBuilder getCitiesOrBuilder(
- int index) {
- return cities_.get(index);
- }
// repeated .CityBlockIndex blocks = 7;
public static final int BLOCKS_FIELD_NUMBER = 7;
- private java.util.List blocks_;
+ private java.util.List blocks_ =
+ java.util.Collections.emptyList();
public java.util.List getBlocksList() {
return blocks_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.CityBlockIndexOrBuilder>
- getBlocksOrBuilderList() {
- return blocks_;
- }
- public int getBlocksCount() {
- return blocks_.size();
- }
+ public int getBlocksCount() { return blocks_.size(); }
public net.osmand.binary.OsmandOdb.CityBlockIndex getBlocks(int index) {
return blocks_.get(index);
}
- public net.osmand.binary.OsmandOdb.CityBlockIndexOrBuilder getBlocksOrBuilder(
- int index) {
- return blocks_.get(index);
- }
private void initFields() {
- type_ = 0;
- cities_ = java.util.Collections.emptyList();
- blocks_ = java.util.Collections.emptyList();
}
- private byte memoizedIsInitialized = -1;
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized != -1) return isInitialized == 1;
-
- if (!hasType()) {
- memoizedIsInitialized = 0;
- return false;
+ @Override
+ public final boolean isInitialized() {
+ if (!hasType) return false;
+ for (net.osmand.binary.OsmandOdb.CityIndex element : getCitiesList()) {
+ if (!element.isInitialized()) return false;
}
- for (int i = 0; i < getCitiesCount(); i++) {
- if (!getCities(i).isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
+ for (net.osmand.binary.OsmandOdb.CityBlockIndex element : getBlocksList()) {
+ if (!element.isInitialized()) return false;
}
- for (int i = 0; i < getBlocksCount(); i++) {
- if (!getBlocks(i).isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
- }
- memoizedIsInitialized = 1;
return true;
}
- public void writeTo(com.google.protobuf.CodedOutputStream output)
+ @Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
- output.writeUInt32(2, type_);
+ if (hasType()) {
+ output.writeUInt32(2, getType());
}
- for (int i = 0; i < cities_.size(); i++) {
- output.writeMessage(5, cities_.get(i));
+ for (net.osmand.binary.OsmandOdb.CityIndex element : getCitiesList()) {
+ output.writeMessage(5, element);
}
- for (int i = 0; i < blocks_.size(); i++) {
- output.writeMessage(7, blocks_.get(i));
+ for (net.osmand.binary.OsmandOdb.CityBlockIndex element : getBlocksList()) {
+ output.writeMessage(7, element);
}
getUnknownFields().writeTo(output);
}
private int memoizedSerializedSize = -1;
- public int getSerializedSize() {
+ @Override
+ public int getSerializedSize() {
int size = memoizedSerializedSize;
if (size != -1) return size;
size = 0;
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ if (hasType()) {
size += com.google.protobuf.CodedOutputStream
- .computeUInt32Size(2, type_);
+ .computeUInt32Size(2, getType());
}
- for (int i = 0; i < cities_.size(); i++) {
+ for (net.osmand.binary.OsmandOdb.CityIndex element : getCitiesList()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(5, cities_.get(i));
+ .computeMessageSize(5, element);
}
- for (int i = 0; i < blocks_.size(); i++) {
+ for (net.osmand.binary.OsmandOdb.CityBlockIndex element : getBlocksList()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(7, blocks_.get(i));
+ .computeMessageSize(7, element);
}
size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size;
return size;
}
- private static final long serialVersionUID = 0L;
- @java.lang.Override
- protected java.lang.Object writeReplace()
- throws java.io.ObjectStreamException {
- return super.writeReplace();
- }
-
public static net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
@@ -9604,132 +5880,100 @@ public final class OsmandOdb {
}
public static Builder newBuilder() { return Builder.create(); }
- public Builder newBuilderForType() { return newBuilder(); }
+ @Override
+ public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder(net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex prototype) {
return newBuilder().mergeFrom(prototype);
}
- public Builder toBuilder() { return newBuilder(this); }
+ @Override
+ public Builder toBuilder() { return newBuilder(this); }
- @java.lang.Override
- protected Builder newBuilderForType(
- com.google.protobuf.GeneratedMessage.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
public static final class Builder extends
- com.google.protobuf.GeneratedMessage.Builder
- implements net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndexOrBuilder {
- public static final com.google.protobuf.Descriptors.Descriptor
- getDescriptor() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndAddressIndex_CitiesIndex_descriptor;
- }
-
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
- internalGetFieldAccessorTable() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndAddressIndex_CitiesIndex_fieldAccessorTable;
- }
+ com.google.protobuf.GeneratedMessage.Builder {
+ private net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex result;
// Construct using net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.newBuilder()
- private Builder() {
- maybeForceBuilderInitialization();
- }
+ private Builder() {}
- private Builder(BuilderParent parent) {
- super(parent);
- maybeForceBuilderInitialization();
- }
- private void maybeForceBuilderInitialization() {
- if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
- getCitiesFieldBuilder();
- getBlocksFieldBuilder();
- }
- }
private static Builder create() {
- return new Builder();
+ Builder builder = new Builder();
+ builder.result = new net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex();
+ return builder;
}
- public Builder clear() {
- super.clear();
- type_ = 0;
- bitField0_ = (bitField0_ & ~0x00000001);
- if (citiesBuilder_ == null) {
- cities_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000002);
- } else {
- citiesBuilder_.clear();
- }
- if (blocksBuilder_ == null) {
- blocks_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000004);
- } else {
- blocksBuilder_.clear();
+ @Override
+ protected net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex internalGetResult() {
+ return result;
+ }
+
+ @Override
+ public Builder clear() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "Cannot call clear() after build().");
}
+ result = new net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex();
return this;
}
- public Builder clone() {
- return create().mergeFrom(buildPartial());
+ @Override
+ public Builder clone() {
+ return create().mergeFrom(result);
}
- public com.google.protobuf.Descriptors.Descriptor
+ @Override
+ public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.getDescriptor();
}
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex getDefaultInstanceForType() {
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex getDefaultInstanceForType() {
return net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.getDefaultInstance();
}
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex build() {
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex result = buildPartial();
- if (!result.isInitialized()) {
+ @Override
+ public boolean isInitialized() {
+ return result.isInitialized();
+ }
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex build() {
+ if (result != null && !isInitialized()) {
throw newUninitializedMessageException(result);
}
- return result;
+ return buildPartial();
}
private net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex buildParsed()
throws com.google.protobuf.InvalidProtocolBufferException {
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex result = buildPartial();
- if (!result.isInitialized()) {
+ if (!isInitialized()) {
throw newUninitializedMessageException(
result).asInvalidProtocolBufferException();
}
- return result;
+ return buildPartial();
}
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex buildPartial() {
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex result = new net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex(this);
- int from_bitField0_ = bitField0_;
- int to_bitField0_ = 0;
- if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
- to_bitField0_ |= 0x00000001;
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex buildPartial() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "build() has already been called on this Builder.");
}
- result.type_ = type_;
- if (citiesBuilder_ == null) {
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
- cities_ = java.util.Collections.unmodifiableList(cities_);
- bitField0_ = (bitField0_ & ~0x00000002);
- }
- result.cities_ = cities_;
- } else {
- result.cities_ = citiesBuilder_.build();
+ if (result.cities_ != java.util.Collections.EMPTY_LIST) {
+ result.cities_ =
+ java.util.Collections.unmodifiableList(result.cities_);
}
- if (blocksBuilder_ == null) {
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
- blocks_ = java.util.Collections.unmodifiableList(blocks_);
- bitField0_ = (bitField0_ & ~0x00000004);
- }
- result.blocks_ = blocks_;
- } else {
- result.blocks_ = blocksBuilder_.build();
+ if (result.blocks_ != java.util.Collections.EMPTY_LIST) {
+ result.blocks_ =
+ java.util.Collections.unmodifiableList(result.blocks_);
}
- result.bitField0_ = to_bitField0_;
- onBuilt();
- return result;
+ net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex returnMe = result;
+ result = null;
+ return returnMe;
}
- public Builder mergeFrom(com.google.protobuf.Message other) {
+ @Override
+ public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex) {
return mergeFrom((net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex)other);
} else {
@@ -9743,83 +5987,24 @@ public final class OsmandOdb {
if (other.hasType()) {
setType(other.getType());
}
- if (citiesBuilder_ == null) {
- if (!other.cities_.isEmpty()) {
- if (cities_.isEmpty()) {
- cities_ = other.cities_;
- bitField0_ = (bitField0_ & ~0x00000002);
- } else {
- ensureCitiesIsMutable();
- cities_.addAll(other.cities_);
- }
- onChanged();
- }
- } else {
- if (!other.cities_.isEmpty()) {
- if (citiesBuilder_.isEmpty()) {
- citiesBuilder_.dispose();
- citiesBuilder_ = null;
- cities_ = other.cities_;
- bitField0_ = (bitField0_ & ~0x00000002);
- citiesBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getCitiesFieldBuilder() : null;
- } else {
- citiesBuilder_.addAllMessages(other.cities_);
- }
+ if (!other.cities_.isEmpty()) {
+ if (result.cities_.isEmpty()) {
+ result.cities_ = new java.util.ArrayList();
}
+ result.cities_.addAll(other.cities_);
}
- if (blocksBuilder_ == null) {
- if (!other.blocks_.isEmpty()) {
- if (blocks_.isEmpty()) {
- blocks_ = other.blocks_;
- bitField0_ = (bitField0_ & ~0x00000004);
- } else {
- ensureBlocksIsMutable();
- blocks_.addAll(other.blocks_);
- }
- onChanged();
- }
- } else {
- if (!other.blocks_.isEmpty()) {
- if (blocksBuilder_.isEmpty()) {
- blocksBuilder_.dispose();
- blocksBuilder_ = null;
- blocks_ = other.blocks_;
- bitField0_ = (bitField0_ & ~0x00000004);
- blocksBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getBlocksFieldBuilder() : null;
- } else {
- blocksBuilder_.addAllMessages(other.blocks_);
- }
+ if (!other.blocks_.isEmpty()) {
+ if (result.blocks_.isEmpty()) {
+ result.blocks_ = new java.util.ArrayList();
}
+ result.blocks_.addAll(other.blocks_);
}
this.mergeUnknownFields(other.getUnknownFields());
return this;
}
- public final boolean isInitialized() {
- if (!hasType()) {
-
- return false;
- }
- for (int i = 0; i < getCitiesCount(); i++) {
- if (!getCities(i).isInitialized()) {
-
- return false;
- }
- }
- for (int i = 0; i < getBlocksCount(); i++) {
- if (!getBlocks(i).isInitialized()) {
-
- return false;
- }
- }
- return true;
- }
-
- public Builder mergeFrom(
+ @Override
+ public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
@@ -9831,20 +6016,17 @@ public final class OsmandOdb {
switch (tag) {
case 0:
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
default: {
if (!parseUnknownField(input, unknownFields,
extensionRegistry, tag)) {
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
}
break;
}
case 16: {
- bitField0_ |= 0x00000001;
- type_ = input.readUInt32();
+ setType(input.readUInt32());
break;
}
case 42: {
@@ -9863,621 +6045,252 @@ public final class OsmandOdb {
}
}
- private int bitField0_;
// required uint32 type = 2;
- private int type_ ;
public boolean hasType() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
+ return result.hasType();
}
public int getType() {
- return type_;
+ return result.getType();
}
public Builder setType(int value) {
- bitField0_ |= 0x00000001;
- type_ = value;
- onChanged();
+ result.hasType = true;
+ result.type_ = value;
return this;
}
public Builder clearType() {
- bitField0_ = (bitField0_ & ~0x00000001);
- type_ = 0;
- onChanged();
+ result.hasType = false;
+ result.type_ = 0;
return this;
}
// repeated .CityIndex cities = 5;
- private java.util.List cities_ =
- java.util.Collections.emptyList();
- private void ensureCitiesIsMutable() {
- if (!((bitField0_ & 0x00000002) == 0x00000002)) {
- cities_ = new java.util.ArrayList(cities_);
- bitField0_ |= 0x00000002;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.CityIndex, net.osmand.binary.OsmandOdb.CityIndex.Builder, net.osmand.binary.OsmandOdb.CityIndexOrBuilder> citiesBuilder_;
-
public java.util.List getCitiesList() {
- if (citiesBuilder_ == null) {
- return java.util.Collections.unmodifiableList(cities_);
- } else {
- return citiesBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.cities_);
}
public int getCitiesCount() {
- if (citiesBuilder_ == null) {
- return cities_.size();
- } else {
- return citiesBuilder_.getCount();
- }
+ return result.getCitiesCount();
}
public net.osmand.binary.OsmandOdb.CityIndex getCities(int index) {
- if (citiesBuilder_ == null) {
- return cities_.get(index);
- } else {
- return citiesBuilder_.getMessage(index);
- }
+ return result.getCities(index);
}
- public Builder setCities(
- int index, net.osmand.binary.OsmandOdb.CityIndex value) {
- if (citiesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureCitiesIsMutable();
- cities_.set(index, value);
- onChanged();
- } else {
- citiesBuilder_.setMessage(index, value);
+ public Builder setCities(int index, net.osmand.binary.OsmandOdb.CityIndex value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.cities_.set(index, value);
return this;
}
- public Builder setCities(
- int index, net.osmand.binary.OsmandOdb.CityIndex.Builder builderForValue) {
- if (citiesBuilder_ == null) {
- ensureCitiesIsMutable();
- cities_.set(index, builderForValue.build());
- onChanged();
- } else {
- citiesBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setCities(int index, net.osmand.binary.OsmandOdb.CityIndex.Builder builderForValue) {
+ result.cities_.set(index, builderForValue.build());
return this;
}
public Builder addCities(net.osmand.binary.OsmandOdb.CityIndex value) {
- if (citiesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureCitiesIsMutable();
- cities_.add(value);
- onChanged();
- } else {
- citiesBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.cities_.isEmpty()) {
+ result.cities_ = new java.util.ArrayList();
+ }
+ result.cities_.add(value);
return this;
}
- public Builder addCities(
- int index, net.osmand.binary.OsmandOdb.CityIndex value) {
- if (citiesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureCitiesIsMutable();
- cities_.add(index, value);
- onChanged();
- } else {
- citiesBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addCities(
- net.osmand.binary.OsmandOdb.CityIndex.Builder builderForValue) {
- if (citiesBuilder_ == null) {
- ensureCitiesIsMutable();
- cities_.add(builderForValue.build());
- onChanged();
- } else {
- citiesBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addCities(
- int index, net.osmand.binary.OsmandOdb.CityIndex.Builder builderForValue) {
- if (citiesBuilder_ == null) {
- ensureCitiesIsMutable();
- cities_.add(index, builderForValue.build());
- onChanged();
- } else {
- citiesBuilder_.addMessage(index, builderForValue.build());
+ public Builder addCities(net.osmand.binary.OsmandOdb.CityIndex.Builder builderForValue) {
+ if (result.cities_.isEmpty()) {
+ result.cities_ = new java.util.ArrayList();
}
+ result.cities_.add(builderForValue.build());
return this;
}
public Builder addAllCities(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.CityIndex> values) {
- if (citiesBuilder_ == null) {
- ensureCitiesIsMutable();
- super.addAll(values, cities_);
- onChanged();
- } else {
- citiesBuilder_.addAllMessages(values);
+ if (result.cities_.isEmpty()) {
+ result.cities_ = new java.util.ArrayList();
}
+ super.addAll(values, result.cities_);
return this;
}
public Builder clearCities() {
- if (citiesBuilder_ == null) {
- cities_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000002);
- onChanged();
- } else {
- citiesBuilder_.clear();
- }
+ result.cities_ = java.util.Collections.emptyList();
return this;
}
- public Builder removeCities(int index) {
- if (citiesBuilder_ == null) {
- ensureCitiesIsMutable();
- cities_.remove(index);
- onChanged();
- } else {
- citiesBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.CityIndex.Builder getCitiesBuilder(
- int index) {
- return getCitiesFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.CityIndexOrBuilder getCitiesOrBuilder(
- int index) {
- if (citiesBuilder_ == null) {
- return cities_.get(index); } else {
- return citiesBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.CityIndexOrBuilder>
- getCitiesOrBuilderList() {
- if (citiesBuilder_ != null) {
- return citiesBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(cities_);
- }
- }
- public net.osmand.binary.OsmandOdb.CityIndex.Builder addCitiesBuilder() {
- return getCitiesFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.CityIndex.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.CityIndex.Builder addCitiesBuilder(
- int index) {
- return getCitiesFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.CityIndex.getDefaultInstance());
- }
- public java.util.List
- getCitiesBuilderList() {
- return getCitiesFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.CityIndex, net.osmand.binary.OsmandOdb.CityIndex.Builder, net.osmand.binary.OsmandOdb.CityIndexOrBuilder>
- getCitiesFieldBuilder() {
- if (citiesBuilder_ == null) {
- citiesBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.CityIndex, net.osmand.binary.OsmandOdb.CityIndex.Builder, net.osmand.binary.OsmandOdb.CityIndexOrBuilder>(
- cities_,
- ((bitField0_ & 0x00000002) == 0x00000002),
- getParentForChildren(),
- isClean());
- cities_ = null;
- }
- return citiesBuilder_;
- }
// repeated .CityBlockIndex blocks = 7;
- private java.util.List blocks_ =
- java.util.Collections.emptyList();
- private void ensureBlocksIsMutable() {
- if (!((bitField0_ & 0x00000004) == 0x00000004)) {
- blocks_ = new java.util.ArrayList(blocks_);
- bitField0_ |= 0x00000004;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.CityBlockIndex, net.osmand.binary.OsmandOdb.CityBlockIndex.Builder, net.osmand.binary.OsmandOdb.CityBlockIndexOrBuilder> blocksBuilder_;
-
public java.util.List getBlocksList() {
- if (blocksBuilder_ == null) {
- return java.util.Collections.unmodifiableList(blocks_);
- } else {
- return blocksBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.blocks_);
}
public int getBlocksCount() {
- if (blocksBuilder_ == null) {
- return blocks_.size();
- } else {
- return blocksBuilder_.getCount();
- }
+ return result.getBlocksCount();
}
public net.osmand.binary.OsmandOdb.CityBlockIndex getBlocks(int index) {
- if (blocksBuilder_ == null) {
- return blocks_.get(index);
- } else {
- return blocksBuilder_.getMessage(index);
- }
+ return result.getBlocks(index);
}
- public Builder setBlocks(
- int index, net.osmand.binary.OsmandOdb.CityBlockIndex value) {
- if (blocksBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBlocksIsMutable();
- blocks_.set(index, value);
- onChanged();
- } else {
- blocksBuilder_.setMessage(index, value);
+ public Builder setBlocks(int index, net.osmand.binary.OsmandOdb.CityBlockIndex value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.blocks_.set(index, value);
return this;
}
- public Builder setBlocks(
- int index, net.osmand.binary.OsmandOdb.CityBlockIndex.Builder builderForValue) {
- if (blocksBuilder_ == null) {
- ensureBlocksIsMutable();
- blocks_.set(index, builderForValue.build());
- onChanged();
- } else {
- blocksBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setBlocks(int index, net.osmand.binary.OsmandOdb.CityBlockIndex.Builder builderForValue) {
+ result.blocks_.set(index, builderForValue.build());
return this;
}
public Builder addBlocks(net.osmand.binary.OsmandOdb.CityBlockIndex value) {
- if (blocksBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBlocksIsMutable();
- blocks_.add(value);
- onChanged();
- } else {
- blocksBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.blocks_.isEmpty()) {
+ result.blocks_ = new java.util.ArrayList();
+ }
+ result.blocks_.add(value);
return this;
}
- public Builder addBlocks(
- int index, net.osmand.binary.OsmandOdb.CityBlockIndex value) {
- if (blocksBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBlocksIsMutable();
- blocks_.add(index, value);
- onChanged();
- } else {
- blocksBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addBlocks(
- net.osmand.binary.OsmandOdb.CityBlockIndex.Builder builderForValue) {
- if (blocksBuilder_ == null) {
- ensureBlocksIsMutable();
- blocks_.add(builderForValue.build());
- onChanged();
- } else {
- blocksBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addBlocks(
- int index, net.osmand.binary.OsmandOdb.CityBlockIndex.Builder builderForValue) {
- if (blocksBuilder_ == null) {
- ensureBlocksIsMutable();
- blocks_.add(index, builderForValue.build());
- onChanged();
- } else {
- blocksBuilder_.addMessage(index, builderForValue.build());
+ public Builder addBlocks(net.osmand.binary.OsmandOdb.CityBlockIndex.Builder builderForValue) {
+ if (result.blocks_.isEmpty()) {
+ result.blocks_ = new java.util.ArrayList();
}
+ result.blocks_.add(builderForValue.build());
return this;
}
public Builder addAllBlocks(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.CityBlockIndex> values) {
- if (blocksBuilder_ == null) {
- ensureBlocksIsMutable();
- super.addAll(values, blocks_);
- onChanged();
- } else {
- blocksBuilder_.addAllMessages(values);
+ if (result.blocks_.isEmpty()) {
+ result.blocks_ = new java.util.ArrayList();
}
+ super.addAll(values, result.blocks_);
return this;
}
public Builder clearBlocks() {
- if (blocksBuilder_ == null) {
- blocks_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000004);
- onChanged();
- } else {
- blocksBuilder_.clear();
- }
+ result.blocks_ = java.util.Collections.emptyList();
return this;
}
- public Builder removeBlocks(int index) {
- if (blocksBuilder_ == null) {
- ensureBlocksIsMutable();
- blocks_.remove(index);
- onChanged();
- } else {
- blocksBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.CityBlockIndex.Builder getBlocksBuilder(
- int index) {
- return getBlocksFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.CityBlockIndexOrBuilder getBlocksOrBuilder(
- int index) {
- if (blocksBuilder_ == null) {
- return blocks_.get(index); } else {
- return blocksBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.CityBlockIndexOrBuilder>
- getBlocksOrBuilderList() {
- if (blocksBuilder_ != null) {
- return blocksBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(blocks_);
- }
- }
- public net.osmand.binary.OsmandOdb.CityBlockIndex.Builder addBlocksBuilder() {
- return getBlocksFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.CityBlockIndex.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.CityBlockIndex.Builder addBlocksBuilder(
- int index) {
- return getBlocksFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.CityBlockIndex.getDefaultInstance());
- }
- public java.util.List
- getBlocksBuilderList() {
- return getBlocksFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.CityBlockIndex, net.osmand.binary.OsmandOdb.CityBlockIndex.Builder, net.osmand.binary.OsmandOdb.CityBlockIndexOrBuilder>
- getBlocksFieldBuilder() {
- if (blocksBuilder_ == null) {
- blocksBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.CityBlockIndex, net.osmand.binary.OsmandOdb.CityBlockIndex.Builder, net.osmand.binary.OsmandOdb.CityBlockIndexOrBuilder>(
- blocks_,
- ((bitField0_ & 0x00000004) == 0x00000004),
- getParentForChildren(),
- isClean());
- blocks_ = null;
- }
- return blocksBuilder_;
- }
// @@protoc_insertion_point(builder_scope:OsmAndAddressIndex.CitiesIndex)
}
static {
defaultInstance = new CitiesIndex(true);
+ net.osmand.binary.OsmandOdb.internalForceInit();
defaultInstance.initFields();
}
// @@protoc_insertion_point(class_scope:OsmAndAddressIndex.CitiesIndex)
}
- private int bitField0_;
// required string name = 1;
public static final int NAME_FIELD_NUMBER = 1;
- private java.lang.Object name_;
- public boolean hasName() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
- }
- public String getName() {
- java.lang.Object ref = name_;
- if (ref instanceof String) {
- return (String) ref;
- } else {
- com.google.protobuf.ByteString bs =
- (com.google.protobuf.ByteString) ref;
- String s = bs.toStringUtf8();
- if (com.google.protobuf.Internal.isValidUtf8(bs)) {
- name_ = s;
- }
- return s;
- }
- }
- private com.google.protobuf.ByteString getNameBytes() {
- java.lang.Object ref = name_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((String) ref);
- name_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
+ private boolean hasName;
+ private java.lang.String name_ = "";
+ public boolean hasName() { return hasName; }
+ public java.lang.String getName() { return name_; }
// optional string name_en = 2;
public static final int NAME_EN_FIELD_NUMBER = 2;
- private java.lang.Object nameEn_;
- public boolean hasNameEn() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
- }
- public String getNameEn() {
- java.lang.Object ref = nameEn_;
- if (ref instanceof String) {
- return (String) ref;
- } else {
- com.google.protobuf.ByteString bs =
- (com.google.protobuf.ByteString) ref;
- String s = bs.toStringUtf8();
- if (com.google.protobuf.Internal.isValidUtf8(bs)) {
- nameEn_ = s;
- }
- return s;
- }
- }
- private com.google.protobuf.ByteString getNameEnBytes() {
- java.lang.Object ref = nameEn_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((String) ref);
- nameEn_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
+ private boolean hasNameEn;
+ private java.lang.String nameEn_ = "";
+ public boolean hasNameEn() { return hasNameEn; }
+ public java.lang.String getNameEn() { return nameEn_; }
// optional .OsmAndTileBox boundaries = 3;
public static final int BOUNDARIES_FIELD_NUMBER = 3;
+ private boolean hasBoundaries;
private net.osmand.binary.OsmandOdb.OsmAndTileBox boundaries_;
- public boolean hasBoundaries() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
- }
- public net.osmand.binary.OsmandOdb.OsmAndTileBox getBoundaries() {
- return boundaries_;
- }
- public net.osmand.binary.OsmandOdb.OsmAndTileBoxOrBuilder getBoundariesOrBuilder() {
- return boundaries_;
- }
+ public boolean hasBoundaries() { return hasBoundaries; }
+ public net.osmand.binary.OsmandOdb.OsmAndTileBox getBoundaries() { return boundaries_; }
// repeated .OsmAndAddressIndex.CitiesIndex cities = 6;
public static final int CITIES_FIELD_NUMBER = 6;
- private java.util.List cities_;
+ private java.util.List cities_ =
+ java.util.Collections.emptyList();
public java.util.List getCitiesList() {
return cities_;
}
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndexOrBuilder>
- getCitiesOrBuilderList() {
- return cities_;
- }
- public int getCitiesCount() {
- return cities_.size();
- }
+ public int getCitiesCount() { return cities_.size(); }
public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex getCities(int index) {
return cities_.get(index);
}
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndexOrBuilder getCitiesOrBuilder(
- int index) {
- return cities_.get(index);
- }
// optional .OsmAndAddressNameIndexData nameIndex = 7;
public static final int NAMEINDEX_FIELD_NUMBER = 7;
+ private boolean hasNameIndex;
private net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData nameIndex_;
- public boolean hasNameIndex() {
- return ((bitField0_ & 0x00000008) == 0x00000008);
- }
- public net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData getNameIndex() {
- return nameIndex_;
- }
- public net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexDataOrBuilder getNameIndexOrBuilder() {
- return nameIndex_;
- }
+ public boolean hasNameIndex() { return hasNameIndex; }
+ public net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData getNameIndex() { return nameIndex_; }
private void initFields() {
- name_ = "";
- nameEn_ = "";
boundaries_ = net.osmand.binary.OsmandOdb.OsmAndTileBox.getDefaultInstance();
- cities_ = java.util.Collections.emptyList();
nameIndex_ = net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.getDefaultInstance();
}
- private byte memoizedIsInitialized = -1;
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized != -1) return isInitialized == 1;
-
- if (!hasName()) {
- memoizedIsInitialized = 0;
- return false;
- }
+ @Override
+ public final boolean isInitialized() {
+ if (!hasName) return false;
if (hasBoundaries()) {
- if (!getBoundaries().isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
+ if (!getBoundaries().isInitialized()) return false;
}
- for (int i = 0; i < getCitiesCount(); i++) {
- if (!getCities(i).isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
+ for (net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex element : getCitiesList()) {
+ if (!element.isInitialized()) return false;
}
if (hasNameIndex()) {
- if (!getNameIndex().isInitialized()) {
- memoizedIsInitialized = 0;
- return false;
- }
+ if (!getNameIndex().isInitialized()) return false;
}
- memoizedIsInitialized = 1;
return true;
}
- public void writeTo(com.google.protobuf.CodedOutputStream output)
+ @Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
- output.writeBytes(1, getNameBytes());
+ if (hasName()) {
+ output.writeString(1, getName());
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
- output.writeBytes(2, getNameEnBytes());
+ if (hasNameEn()) {
+ output.writeString(2, getNameEn());
}
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
- output.writeMessage(3, boundaries_);
+ if (hasBoundaries()) {
+ output.writeMessage(3, getBoundaries());
}
- for (int i = 0; i < cities_.size(); i++) {
- output.writeMessage(6, cities_.get(i));
+ for (net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex element : getCitiesList()) {
+ output.writeMessage(6, element);
}
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
- output.writeMessage(7, nameIndex_);
+ if (hasNameIndex()) {
+ output.writeMessage(7, getNameIndex());
}
getUnknownFields().writeTo(output);
}
private int memoizedSerializedSize = -1;
- public int getSerializedSize() {
+ @Override
+ public int getSerializedSize() {
int size = memoizedSerializedSize;
if (size != -1) return size;
size = 0;
- if (((bitField0_ & 0x00000001) == 0x00000001)) {
+ if (hasName()) {
size += com.google.protobuf.CodedOutputStream
- .computeBytesSize(1, getNameBytes());
+ .computeStringSize(1, getName());
}
- if (((bitField0_ & 0x00000002) == 0x00000002)) {
+ if (hasNameEn()) {
size += com.google.protobuf.CodedOutputStream
- .computeBytesSize(2, getNameEnBytes());
+ .computeStringSize(2, getNameEn());
}
- if (((bitField0_ & 0x00000004) == 0x00000004)) {
+ if (hasBoundaries()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(3, boundaries_);
+ .computeMessageSize(3, getBoundaries());
}
- for (int i = 0; i < cities_.size(); i++) {
+ for (net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex element : getCitiesList()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(6, cities_.get(i));
+ .computeMessageSize(6, element);
}
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
+ if (hasNameIndex()) {
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(7, nameIndex_);
+ .computeMessageSize(7, getNameIndex());
}
size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size;
return size;
}
- private static final long serialVersionUID = 0L;
- @java.lang.Override
- protected java.lang.Object writeReplace()
- throws java.io.ObjectStreamException {
- return super.writeReplace();
- }
-
public static net.osmand.binary.OsmandOdb.OsmAndAddressIndex parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
@@ -10546,152 +6359,96 @@ public final class OsmandOdb {
}
public static Builder newBuilder() { return Builder.create(); }
- public Builder newBuilderForType() { return newBuilder(); }
+ @Override
+ public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder(net.osmand.binary.OsmandOdb.OsmAndAddressIndex prototype) {
return newBuilder().mergeFrom(prototype);
}
- public Builder toBuilder() { return newBuilder(this); }
+ @Override
+ public Builder toBuilder() { return newBuilder(this); }
- @java.lang.Override
- protected Builder newBuilderForType(
- com.google.protobuf.GeneratedMessage.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
public static final class Builder extends
- com.google.protobuf.GeneratedMessage.Builder
- implements net.osmand.binary.OsmandOdb.OsmAndAddressIndexOrBuilder {
- public static final com.google.protobuf.Descriptors.Descriptor
- getDescriptor() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndAddressIndex_descriptor;
- }
-
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
- internalGetFieldAccessorTable() {
- return net.osmand.binary.OsmandOdb.internal_static_OsmAndAddressIndex_fieldAccessorTable;
- }
+ com.google.protobuf.GeneratedMessage.Builder {
+ private net.osmand.binary.OsmandOdb.OsmAndAddressIndex result;
// Construct using net.osmand.binary.OsmandOdb.OsmAndAddressIndex.newBuilder()
- private Builder() {
- maybeForceBuilderInitialization();
- }
+ private Builder() {}
- private Builder(BuilderParent parent) {
- super(parent);
- maybeForceBuilderInitialization();
- }
- private void maybeForceBuilderInitialization() {
- if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
- getBoundariesFieldBuilder();
- getCitiesFieldBuilder();
- getNameIndexFieldBuilder();
- }
- }
private static Builder create() {
- return new Builder();
+ Builder builder = new Builder();
+ builder.result = new net.osmand.binary.OsmandOdb.OsmAndAddressIndex();
+ return builder;
}
- public Builder clear() {
- super.clear();
- name_ = "";
- bitField0_ = (bitField0_ & ~0x00000001);
- nameEn_ = "";
- bitField0_ = (bitField0_ & ~0x00000002);
- if (boundariesBuilder_ == null) {
- boundaries_ = net.osmand.binary.OsmandOdb.OsmAndTileBox.getDefaultInstance();
- } else {
- boundariesBuilder_.clear();
+ @Override
+ protected net.osmand.binary.OsmandOdb.OsmAndAddressIndex internalGetResult() {
+ return result;
+ }
+
+ @Override
+ public Builder clear() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "Cannot call clear() after build().");
}
- bitField0_ = (bitField0_ & ~0x00000004);
- if (citiesBuilder_ == null) {
- cities_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000008);
- } else {
- citiesBuilder_.clear();
- }
- if (nameIndexBuilder_ == null) {
- nameIndex_ = net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.getDefaultInstance();
- } else {
- nameIndexBuilder_.clear();
- }
- bitField0_ = (bitField0_ & ~0x00000010);
+ result = new net.osmand.binary.OsmandOdb.OsmAndAddressIndex();
return this;
}
- public Builder clone() {
- return create().mergeFrom(buildPartial());
+ @Override
+ public Builder clone() {
+ return create().mergeFrom(result);
}
- public com.google.protobuf.Descriptors.Descriptor
+ @Override
+ public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return net.osmand.binary.OsmandOdb.OsmAndAddressIndex.getDescriptor();
}
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndex getDefaultInstanceForType() {
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndAddressIndex getDefaultInstanceForType() {
return net.osmand.binary.OsmandOdb.OsmAndAddressIndex.getDefaultInstance();
}
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndex build() {
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex result = buildPartial();
- if (!result.isInitialized()) {
+ @Override
+ public boolean isInitialized() {
+ return result.isInitialized();
+ }
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndAddressIndex build() {
+ if (result != null && !isInitialized()) {
throw newUninitializedMessageException(result);
}
- return result;
+ return buildPartial();
}
private net.osmand.binary.OsmandOdb.OsmAndAddressIndex buildParsed()
throws com.google.protobuf.InvalidProtocolBufferException {
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex result = buildPartial();
- if (!result.isInitialized()) {
+ if (!isInitialized()) {
throw newUninitializedMessageException(
result).asInvalidProtocolBufferException();
}
- return result;
+ return buildPartial();
}
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndex buildPartial() {
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex result = new net.osmand.binary.OsmandOdb.OsmAndAddressIndex(this);
- int from_bitField0_ = bitField0_;
- int to_bitField0_ = 0;
- if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
- to_bitField0_ |= 0x00000001;
+ @Override
+ public net.osmand.binary.OsmandOdb.OsmAndAddressIndex buildPartial() {
+ if (result == null) {
+ throw new IllegalStateException(
+ "build() has already been called on this Builder.");
}
- result.name_ = name_;
- if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
- to_bitField0_ |= 0x00000002;
+ if (result.cities_ != java.util.Collections.EMPTY_LIST) {
+ result.cities_ =
+ java.util.Collections.unmodifiableList(result.cities_);
}
- result.nameEn_ = nameEn_;
- if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
- to_bitField0_ |= 0x00000004;
- }
- if (boundariesBuilder_ == null) {
- result.boundaries_ = boundaries_;
- } else {
- result.boundaries_ = boundariesBuilder_.build();
- }
- if (citiesBuilder_ == null) {
- if (((bitField0_ & 0x00000008) == 0x00000008)) {
- cities_ = java.util.Collections.unmodifiableList(cities_);
- bitField0_ = (bitField0_ & ~0x00000008);
- }
- result.cities_ = cities_;
- } else {
- result.cities_ = citiesBuilder_.build();
- }
- if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
- to_bitField0_ |= 0x00000008;
- }
- if (nameIndexBuilder_ == null) {
- result.nameIndex_ = nameIndex_;
- } else {
- result.nameIndex_ = nameIndexBuilder_.build();
- }
- result.bitField0_ = to_bitField0_;
- onBuilt();
- return result;
+ net.osmand.binary.OsmandOdb.OsmAndAddressIndex returnMe = result;
+ result = null;
+ return returnMe;
}
- public Builder mergeFrom(com.google.protobuf.Message other) {
+ @Override
+ public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof net.osmand.binary.OsmandOdb.OsmAndAddressIndex) {
return mergeFrom((net.osmand.binary.OsmandOdb.OsmAndAddressIndex)other);
} else {
@@ -10711,31 +6468,11 @@ public final class OsmandOdb {
if (other.hasBoundaries()) {
mergeBoundaries(other.getBoundaries());
}
- if (citiesBuilder_ == null) {
- if (!other.cities_.isEmpty()) {
- if (cities_.isEmpty()) {
- cities_ = other.cities_;
- bitField0_ = (bitField0_ & ~0x00000008);
- } else {
- ensureCitiesIsMutable();
- cities_.addAll(other.cities_);
- }
- onChanged();
- }
- } else {
- if (!other.cities_.isEmpty()) {
- if (citiesBuilder_.isEmpty()) {
- citiesBuilder_.dispose();
- citiesBuilder_ = null;
- cities_ = other.cities_;
- bitField0_ = (bitField0_ & ~0x00000008);
- citiesBuilder_ =
- com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
- getCitiesFieldBuilder() : null;
- } else {
- citiesBuilder_.addAllMessages(other.cities_);
- }
+ if (!other.cities_.isEmpty()) {
+ if (result.cities_.isEmpty()) {
+ result.cities_ = new java.util.ArrayList();
}
+ result.cities_.addAll(other.cities_);
}
if (other.hasNameIndex()) {
mergeNameIndex(other.getNameIndex());
@@ -10744,33 +6481,8 @@ public final class OsmandOdb {
return this;
}
- public final boolean isInitialized() {
- if (!hasName()) {
-
- return false;
- }
- if (hasBoundaries()) {
- if (!getBoundaries().isInitialized()) {
-
- return false;
- }
- }
- for (int i = 0; i < getCitiesCount(); i++) {
- if (!getCities(i).isInitialized()) {
-
- return false;
- }
- }
- if (hasNameIndex()) {
- if (!getNameIndex().isInitialized()) {
-
- return false;
- }
- }
- return true;
- }
-
- public Builder mergeFrom(
+ @Override
+ public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
@@ -10782,25 +6494,21 @@ public final class OsmandOdb {
switch (tag) {
case 0:
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
default: {
if (!parseUnknownField(input, unknownFields,
extensionRegistry, tag)) {
this.setUnknownFields(unknownFields.build());
- onChanged();
return this;
}
break;
}
case 10: {
- bitField0_ |= 0x00000001;
- name_ = input.readBytes();
+ setName(input.readString());
break;
}
case 18: {
- bitField0_ |= 0x00000002;
- nameEn_ = input.readBytes();
+ setNameEn(input.readString());
break;
}
case 26: {
@@ -10831,481 +6539,191 @@ public final class OsmandOdb {
}
}
- private int bitField0_;
// required string name = 1;
- private java.lang.Object name_ = "";
public boolean hasName() {
- return ((bitField0_ & 0x00000001) == 0x00000001);
+ return result.hasName();
}
- public String getName() {
- java.lang.Object ref = name_;
- if (!(ref instanceof String)) {
- String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
- name_ = s;
- return s;
- } else {
- return (String) ref;
- }
+ public java.lang.String getName() {
+ return result.getName();
}
- public Builder setName(String value) {
+ public Builder setName(java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
- bitField0_ |= 0x00000001;
- name_ = value;
- onChanged();
+ result.hasName = true;
+ result.name_ = value;
return this;
}
public Builder clearName() {
- bitField0_ = (bitField0_ & ~0x00000001);
- name_ = getDefaultInstance().getName();
- onChanged();
+ result.hasName = false;
+ result.name_ = getDefaultInstance().getName();
return this;
}
- void setName(com.google.protobuf.ByteString value) {
- bitField0_ |= 0x00000001;
- name_ = value;
- onChanged();
- }
// optional string name_en = 2;
- private java.lang.Object nameEn_ = "";
public boolean hasNameEn() {
- return ((bitField0_ & 0x00000002) == 0x00000002);
+ return result.hasNameEn();
}
- public String getNameEn() {
- java.lang.Object ref = nameEn_;
- if (!(ref instanceof String)) {
- String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
- nameEn_ = s;
- return s;
- } else {
- return (String) ref;
- }
+ public java.lang.String getNameEn() {
+ return result.getNameEn();
}
- public Builder setNameEn(String value) {
+ public Builder setNameEn(java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
- bitField0_ |= 0x00000002;
- nameEn_ = value;
- onChanged();
+ result.hasNameEn = true;
+ result.nameEn_ = value;
return this;
}
public Builder clearNameEn() {
- bitField0_ = (bitField0_ & ~0x00000002);
- nameEn_ = getDefaultInstance().getNameEn();
- onChanged();
+ result.hasNameEn = false;
+ result.nameEn_ = getDefaultInstance().getNameEn();
return this;
}
- void setNameEn(com.google.protobuf.ByteString value) {
- bitField0_ |= 0x00000002;
- nameEn_ = value;
- onChanged();
- }
// optional .OsmAndTileBox boundaries = 3;
- private net.osmand.binary.OsmandOdb.OsmAndTileBox boundaries_ = net.osmand.binary.OsmandOdb.OsmAndTileBox.getDefaultInstance();
- private com.google.protobuf.SingleFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndTileBox, net.osmand.binary.OsmandOdb.OsmAndTileBox.Builder, net.osmand.binary.OsmandOdb.OsmAndTileBoxOrBuilder> boundariesBuilder_;
public boolean hasBoundaries() {
- return ((bitField0_ & 0x00000004) == 0x00000004);
+ return result.hasBoundaries();
}
public net.osmand.binary.OsmandOdb.OsmAndTileBox getBoundaries() {
- if (boundariesBuilder_ == null) {
- return boundaries_;
- } else {
- return boundariesBuilder_.getMessage();
- }
+ return result.getBoundaries();
}
public Builder setBoundaries(net.osmand.binary.OsmandOdb.OsmAndTileBox value) {
- if (boundariesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- boundaries_ = value;
- onChanged();
- } else {
- boundariesBuilder_.setMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
- bitField0_ |= 0x00000004;
+ result.hasBoundaries = true;
+ result.boundaries_ = value;
return this;
}
- public Builder setBoundaries(
- net.osmand.binary.OsmandOdb.OsmAndTileBox.Builder builderForValue) {
- if (boundariesBuilder_ == null) {
- boundaries_ = builderForValue.build();
- onChanged();
- } else {
- boundariesBuilder_.setMessage(builderForValue.build());
- }
- bitField0_ |= 0x00000004;
+ public Builder setBoundaries(net.osmand.binary.OsmandOdb.OsmAndTileBox.Builder builderForValue) {
+ result.hasBoundaries = true;
+ result.boundaries_ = builderForValue.build();
return this;
}
public Builder mergeBoundaries(net.osmand.binary.OsmandOdb.OsmAndTileBox value) {
- if (boundariesBuilder_ == null) {
- if (((bitField0_ & 0x00000004) == 0x00000004) &&
- boundaries_ != net.osmand.binary.OsmandOdb.OsmAndTileBox.getDefaultInstance()) {
- boundaries_ =
- net.osmand.binary.OsmandOdb.OsmAndTileBox.newBuilder(boundaries_).mergeFrom(value).buildPartial();
- } else {
- boundaries_ = value;
- }
- onChanged();
+ if (result.hasBoundaries() &&
+ result.boundaries_ != net.osmand.binary.OsmandOdb.OsmAndTileBox.getDefaultInstance()) {
+ result.boundaries_ =
+ net.osmand.binary.OsmandOdb.OsmAndTileBox.newBuilder(result.boundaries_).mergeFrom(value).buildPartial();
} else {
- boundariesBuilder_.mergeFrom(value);
+ result.boundaries_ = value;
}
- bitField0_ |= 0x00000004;
+ result.hasBoundaries = true;
return this;
}
public Builder clearBoundaries() {
- if (boundariesBuilder_ == null) {
- boundaries_ = net.osmand.binary.OsmandOdb.OsmAndTileBox.getDefaultInstance();
- onChanged();
- } else {
- boundariesBuilder_.clear();
- }
- bitField0_ = (bitField0_ & ~0x00000004);
+ result.hasBoundaries = false;
+ result.boundaries_ = net.osmand.binary.OsmandOdb.OsmAndTileBox.getDefaultInstance();
return this;
}
- public net.osmand.binary.OsmandOdb.OsmAndTileBox.Builder getBoundariesBuilder() {
- bitField0_ |= 0x00000004;
- onChanged();
- return getBoundariesFieldBuilder().getBuilder();
- }
- public net.osmand.binary.OsmandOdb.OsmAndTileBoxOrBuilder getBoundariesOrBuilder() {
- if (boundariesBuilder_ != null) {
- return boundariesBuilder_.getMessageOrBuilder();
- } else {
- return boundaries_;
- }
- }
- private com.google.protobuf.SingleFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndTileBox, net.osmand.binary.OsmandOdb.OsmAndTileBox.Builder, net.osmand.binary.OsmandOdb.OsmAndTileBoxOrBuilder>
- getBoundariesFieldBuilder() {
- if (boundariesBuilder_ == null) {
- boundariesBuilder_ = new com.google.protobuf.SingleFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndTileBox, net.osmand.binary.OsmandOdb.OsmAndTileBox.Builder, net.osmand.binary.OsmandOdb.OsmAndTileBoxOrBuilder>(
- boundaries_,
- getParentForChildren(),
- isClean());
- boundaries_ = null;
- }
- return boundariesBuilder_;
- }
// repeated .OsmAndAddressIndex.CitiesIndex cities = 6;
- private java.util.List cities_ =
- java.util.Collections.emptyList();
- private void ensureCitiesIsMutable() {
- if (!((bitField0_ & 0x00000008) == 0x00000008)) {
- cities_ = new java.util.ArrayList(cities_);
- bitField0_ |= 0x00000008;
- }
- }
-
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndexOrBuilder> citiesBuilder_;
-
public java.util.List getCitiesList() {
- if (citiesBuilder_ == null) {
- return java.util.Collections.unmodifiableList(cities_);
- } else {
- return citiesBuilder_.getMessageList();
- }
+ return java.util.Collections.unmodifiableList(result.cities_);
}
public int getCitiesCount() {
- if (citiesBuilder_ == null) {
- return cities_.size();
- } else {
- return citiesBuilder_.getCount();
- }
+ return result.getCitiesCount();
}
public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex getCities(int index) {
- if (citiesBuilder_ == null) {
- return cities_.get(index);
- } else {
- return citiesBuilder_.getMessage(index);
- }
+ return result.getCities(index);
}
- public Builder setCities(
- int index, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex value) {
- if (citiesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureCitiesIsMutable();
- cities_.set(index, value);
- onChanged();
- } else {
- citiesBuilder_.setMessage(index, value);
+ public Builder setCities(int index, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex value) {
+ if (value == null) {
+ throw new NullPointerException();
}
+ result.cities_.set(index, value);
return this;
}
- public Builder setCities(
- int index, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.Builder builderForValue) {
- if (citiesBuilder_ == null) {
- ensureCitiesIsMutable();
- cities_.set(index, builderForValue.build());
- onChanged();
- } else {
- citiesBuilder_.setMessage(index, builderForValue.build());
- }
+ public Builder setCities(int index, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.Builder builderForValue) {
+ result.cities_.set(index, builderForValue.build());
return this;
}
public Builder addCities(net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex value) {
- if (citiesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureCitiesIsMutable();
- cities_.add(value);
- onChanged();
- } else {
- citiesBuilder_.addMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
+ if (result.cities_.isEmpty()) {
+ result.cities_ = new java.util.ArrayList();
+ }
+ result.cities_.add(value);
return this;
}
- public Builder addCities(
- int index, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex value) {
- if (citiesBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureCitiesIsMutable();
- cities_.add(index, value);
- onChanged();
- } else {
- citiesBuilder_.addMessage(index, value);
- }
- return this;
- }
- public Builder addCities(
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.Builder builderForValue) {
- if (citiesBuilder_ == null) {
- ensureCitiesIsMutable();
- cities_.add(builderForValue.build());
- onChanged();
- } else {
- citiesBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- public Builder addCities(
- int index, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.Builder builderForValue) {
- if (citiesBuilder_ == null) {
- ensureCitiesIsMutable();
- cities_.add(index, builderForValue.build());
- onChanged();
- } else {
- citiesBuilder_.addMessage(index, builderForValue.build());
+ public Builder addCities(net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.Builder builderForValue) {
+ if (result.cities_.isEmpty()) {
+ result.cities_ = new java.util.ArrayList();
}
+ result.cities_.add(builderForValue.build());
return this;
}
public Builder addAllCities(
java.lang.Iterable extends net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex> values) {
- if (citiesBuilder_ == null) {
- ensureCitiesIsMutable();
- super.addAll(values, cities_);
- onChanged();
- } else {
- citiesBuilder_.addAllMessages(values);
+ if (result.cities_.isEmpty()) {
+ result.cities_ = new java.util.ArrayList();
}
+ super.addAll(values, result.cities_);
return this;
}
public Builder clearCities() {
- if (citiesBuilder_ == null) {
- cities_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000008);
- onChanged();
- } else {
- citiesBuilder_.clear();
- }
+ result.cities_ = java.util.Collections.emptyList();
return this;
}
- public Builder removeCities(int index) {
- if (citiesBuilder_ == null) {
- ensureCitiesIsMutable();
- cities_.remove(index);
- onChanged();
- } else {
- citiesBuilder_.remove(index);
- }
- return this;
- }
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.Builder getCitiesBuilder(
- int index) {
- return getCitiesFieldBuilder().getBuilder(index);
- }
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndexOrBuilder getCitiesOrBuilder(
- int index) {
- if (citiesBuilder_ == null) {
- return cities_.get(index); } else {
- return citiesBuilder_.getMessageOrBuilder(index);
- }
- }
- public java.util.List extends net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndexOrBuilder>
- getCitiesOrBuilderList() {
- if (citiesBuilder_ != null) {
- return citiesBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(cities_);
- }
- }
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.Builder addCitiesBuilder() {
- return getCitiesFieldBuilder().addBuilder(
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.getDefaultInstance());
- }
- public net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.Builder addCitiesBuilder(
- int index) {
- return getCitiesFieldBuilder().addBuilder(
- index, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.getDefaultInstance());
- }
- public java.util.List
- getCitiesBuilderList() {
- return getCitiesFieldBuilder().getBuilderList();
- }
- private com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndexOrBuilder>
- getCitiesFieldBuilder() {
- if (citiesBuilder_ == null) {
- citiesBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndex.Builder, net.osmand.binary.OsmandOdb.OsmAndAddressIndex.CitiesIndexOrBuilder>(
- cities_,
- ((bitField0_ & 0x00000008) == 0x00000008),
- getParentForChildren(),
- isClean());
- cities_ = null;
- }
- return citiesBuilder_;
- }
// optional .OsmAndAddressNameIndexData nameIndex = 7;
- private net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData nameIndex_ = net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.getDefaultInstance();
- private com.google.protobuf.SingleFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData, net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.Builder, net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexDataOrBuilder> nameIndexBuilder_;
public boolean hasNameIndex() {
- return ((bitField0_ & 0x00000010) == 0x00000010);
+ return result.hasNameIndex();
}
public net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData getNameIndex() {
- if (nameIndexBuilder_ == null) {
- return nameIndex_;
- } else {
- return nameIndexBuilder_.getMessage();
- }
+ return result.getNameIndex();
}
public Builder setNameIndex(net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData value) {
- if (nameIndexBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- nameIndex_ = value;
- onChanged();
- } else {
- nameIndexBuilder_.setMessage(value);
+ if (value == null) {
+ throw new NullPointerException();
}
- bitField0_ |= 0x00000010;
+ result.hasNameIndex = true;
+ result.nameIndex_ = value;
return this;
}
- public Builder setNameIndex(
- net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.Builder builderForValue) {
- if (nameIndexBuilder_ == null) {
- nameIndex_ = builderForValue.build();
- onChanged();
- } else {
- nameIndexBuilder_.setMessage(builderForValue.build());
- }
- bitField0_ |= 0x00000010;
+ public Builder setNameIndex(net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.Builder builderForValue) {
+ result.hasNameIndex = true;
+ result.nameIndex_ = builderForValue.build();
return this;
}
public Builder mergeNameIndex(net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData value) {
- if (nameIndexBuilder_ == null) {
- if (((bitField0_ & 0x00000010) == 0x00000010) &&
- nameIndex_ != net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.getDefaultInstance()) {
- nameIndex_ =
- net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.newBuilder(nameIndex_).mergeFrom(value).buildPartial();
- } else {
- nameIndex_ = value;
- }
- onChanged();
+ if (result.hasNameIndex() &&
+ result.nameIndex_ != net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.getDefaultInstance()) {
+ result.nameIndex_ =
+ net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.newBuilder(result.nameIndex_).mergeFrom(value).buildPartial();
} else {
- nameIndexBuilder_.mergeFrom(value);
+ result.nameIndex_ = value;
}
- bitField0_ |= 0x00000010;
+ result.hasNameIndex = true;
return this;
}
public Builder clearNameIndex() {
- if (nameIndexBuilder_ == null) {
- nameIndex_ = net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.getDefaultInstance();
- onChanged();
- } else {
- nameIndexBuilder_.clear();
- }
- bitField0_ = (bitField0_ & ~0x00000010);
+ result.hasNameIndex = false;
+ result.nameIndex_ = net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.getDefaultInstance();
return this;
}
- public net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.Builder getNameIndexBuilder() {
- bitField0_ |= 0x00000010;
- onChanged();
- return getNameIndexFieldBuilder().getBuilder();
- }
- public net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexDataOrBuilder getNameIndexOrBuilder() {
- if (nameIndexBuilder_ != null) {
- return nameIndexBuilder_.getMessageOrBuilder();
- } else {
- return nameIndex_;
- }
- }
- private com.google.protobuf.SingleFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData, net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.Builder, net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexDataOrBuilder>
- getNameIndexFieldBuilder() {
- if (nameIndexBuilder_ == null) {
- nameIndexBuilder_ = new com.google.protobuf.SingleFieldBuilder<
- net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData, net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.Builder, net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexDataOrBuilder>(
- nameIndex_,
- getParentForChildren(),
- isClean());
- nameIndex_ = null;
- }
- return nameIndexBuilder_;
- }
// @@protoc_insertion_point(builder_scope:OsmAndAddressIndex)
}
static {
defaultInstance = new OsmAndAddressIndex(true);
+ net.osmand.binary.OsmandOdb.internalForceInit();
defaultInstance.initFields();
}
// @@protoc_insertion_point(class_scope:OsmAndAddressIndex)
}
- public interface OsmAndAddressNameIndexDataOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // repeated .OsmAndAddressNameIndexData.AddressNameIndexDataBlocks blocks = 3;
- java.util.List
- getBlocksList();
- net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.AddressNameIndexDataBlocks getBlocks(int index);
- int getBlocksCount();
- java.util.List extends net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.AddressNameIndexDataBlocksOrBuilder>
- getBlocksOrBuilderList();
- net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.AddressNameIndexDataBlocksOrBuilder getBlocksOrBuilder(
- int index);
-
- // required .IndexedStringTable table = 4;
- boolean hasTable();
- net.osmand.binary.OsmandOdb.IndexedStringTable getTable();
- net.osmand.binary.OsmandOdb.IndexedStringTableOrBuilder getTableOrBuilder();
- }
public static final class OsmAndAddressNameIndexData extends
- com.google.protobuf.GeneratedMessage
- implements OsmAndAddressNameIndexDataOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use OsmAndAddressNameIndexData.newBuilder() to construct.
- private OsmAndAddressNameIndexData(Builder builder) {
- super(builder);
+ private OsmAndAddressNameIndexData() {
+ initFields();
}
private OsmAndAddressNameIndexData(boolean noInit) {}
@@ -11314,7 +6732,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public OsmAndAddressNameIndexData getDefaultInstanceForType() {
+ @Override
+ public OsmAndAddressNameIndexData getDefaultInstanceForType() {
return defaultInstance;
}
@@ -11323,30 +6742,17 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndAddressNameIndexData_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndAddressNameIndexData_fieldAccessorTable;
}
- public interface AddressNameIndexDataBlocksOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // repeated .OsmAndAddressNameIndexData.AddressNameIndexDataBlocks.AddressNameIndexData atom = 4;
- java.util.List
- getAtomList();
- net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.AddressNameIndexDataBlocks.AddressNameIndexData getAtom(int index);
- int getAtomCount();
- java.util.List extends net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.AddressNameIndexDataBlocks.AddressNameIndexDataOrBuilder>
- getAtomOrBuilderList();
- net.osmand.binary.OsmandOdb.OsmAndAddressNameIndexData.AddressNameIndexDataBlocks.AddressNameIndexDataOrBuilder getAtomOrBuilder(
- int index);
- }
public static final class AddressNameIndexDataBlocks extends
- com.google.protobuf.GeneratedMessage
- implements AddressNameIndexDataBlocksOrBuilder {
+ com.google.protobuf.GeneratedMessage {
// Use AddressNameIndexDataBlocks.newBuilder() to construct.
- private AddressNameIndexDataBlocks(Builder builder) {
- super(builder);
+ private AddressNameIndexDataBlocks() {
+ initFields();
}
private AddressNameIndexDataBlocks(boolean noInit) {}
@@ -11355,7 +6761,8 @@ public final class OsmandOdb {
return defaultInstance;
}
- public AddressNameIndexDataBlocks getDefaultInstanceForType() {
+ @Override
+ public AddressNameIndexDataBlocks getDefaultInstanceForType() {
return defaultInstance;
}
@@ -11364,30 +6771,17 @@ public final class OsmandOdb {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndAddressNameIndexData_AddressNameIndexDataBlocks_descriptor;
}
- protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ @Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return net.osmand.binary.OsmandOdb.internal_static_OsmAndAddressNameIndexData_AddressNameIndexDataBlocks_fieldAccessorTable;
}
- public interface AddressNameIndexDataOrBuilder
- extends com.google.protobuf.MessageOrBuilder {
-
- // repeated .AddressNameIndexDataAtom atom = 4;
- java.util.List