Java 类com.google.protobuf.Internal.ProtobufList 实例源码

项目:play-store-api    文件:GeneratedMessageLite.java   
@Override
public <T> ProtobufList<T> visitList(ProtobufList<T> mine, ProtobufList<T> other) {
  if (!mine.equals(other)) {
    throw NOT_EQUALS;
  }
  return mine;
}
项目:play-store-api    文件:GeneratedMessageLite.java   
@Override
public <T> ProtobufList<T> visitList(ProtobufList<T> mine, ProtobufList<T> other) {
  int size = mine.size();
  int otherSize = other.size();
  if (size > 0 && otherSize > 0) {
    if (!mine.isModifiable()) {
      mine = mine.mutableCopyWithCapacity(size + otherSize);
    }
    mine.addAll(other);
  }

  return size > 0 ? mine : other;
}
项目:bazel    文件:GeneratedMessageLite.java   
@Override
public <T> ProtobufList<T> visitList(ProtobufList<T> mine, ProtobufList<T> other) {
  if (!mine.equals(other)) {
    throw NOT_EQUALS;
  }
  return mine;
}
项目:bazel    文件:GeneratedMessageLite.java   
@Override
public <T> ProtobufList<T> visitList(ProtobufList<T> mine, ProtobufList<T> other) {
  int size = mine.size();
  int otherSize = other.size();
  if (size > 0 && otherSize > 0) {
    if (!mine.isModifiable()) {
      mine = mine.mutableCopyWithCapacity(size + otherSize);
    }
    mine.addAll(other);
  }

  return size > 0 ? mine : other;
}
项目:cfapi    文件:GeneratedMessageLite.java   
protected static <E> ProtobufList<E> newProtobufList() {
  return new ProtobufArrayList<E>();
}
项目:cfapi    文件:GeneratedMessageLite.java   
protected static <E> ProtobufList<E> newProtobufList(List<E> toCopy) {
  return new ProtobufArrayList<E>(toCopy);
}
项目:cfapi    文件:GeneratedMessageLite.java   
protected static <E> ProtobufList<E> emptyProtobufList() {
  return ProtobufArrayList.emptyList();
}
项目:play-store-api    文件:GeneratedMessageLite.java   
protected static <E> ProtobufList<E> emptyProtobufList() {
  return ProtobufArrayList.emptyList();
}
项目:play-store-api    文件:GeneratedMessageLite.java   
protected static <E> ProtobufList<E> mutableCopy(ProtobufList<E> list) {
  int size = list.size();
  return list.mutableCopyWithCapacity(
      size == 0 ? AbstractProtobufList.DEFAULT_CAPACITY : size * 2);
}
项目:play-store-api    文件:GeneratedMessageLite.java   
@Override
public <T> ProtobufList<T> visitList(ProtobufList<T> mine, ProtobufList<T> other) {
  hashCode = (53 * hashCode) + mine.hashCode();
  return mine;
}
项目:bazel    文件:GeneratedMessageLite.java   
protected static <E> ProtobufList<E> emptyProtobufList() {
  return ProtobufArrayList.emptyList();
}
项目:bazel    文件:GeneratedMessageLite.java   
protected static <E> ProtobufList<E> mutableCopy(ProtobufList<E> list) {
  int size = list.size();
  return list.mutableCopyWithCapacity(
      size == 0 ? AbstractProtobufList.DEFAULT_CAPACITY : size * 2);
}
项目:bazel    文件:GeneratedMessageLite.java   
@Override
public <T> ProtobufList<T> visitList(ProtobufList<T> mine, ProtobufList<T> other) {
  hashCode = (53 * hashCode) + mine.hashCode();
  return mine;
}
项目:play-store-api    文件:GeneratedMessageLite.java   
<T> ProtobufList<T> visitList(ProtobufList<T> mine, ProtobufList<T> other);
项目:bazel    文件:GeneratedMessageLite.java   
<T> ProtobufList<T> visitList(ProtobufList<T> mine, ProtobufList<T> other);