コード例 #1
0
ファイル: QueryPaths.java プロジェクト: ChenArthur/babyfish
 @Override
 public SimpleOrderPath.Builder get(String nodeName, GetterType getterType) {
   Arguments.mustNotBeEmpty("nodeName", Arguments.mustNotBeNull("nodeName", nodeName));
   Arguments.mustNotBeNull("getterType", getterType);
   Object[] arr = this.arr;
   int len = this.len;
   if (len + 2 > arr.length) {
     Object[] newArr = new Object[len << 1];
     System.arraycopy(arr, 0, newArr, 0, len);
     this.arr = arr = newArr;
   }
   arr[len] = nodeName;
   arr[len + 1] = getterType;
   this.len += 2;
   return this;
 }
コード例 #2
0
 protected DescendingSetImpl(AbstractMAOrderedSet<E> parentSet) {
   super(
       ((OrderedBaseEntries<E, Object>)
               Arguments.mustNotBeNull("parentSet", parentSet).baseEntries)
           .descendingEntries());
   this.parentSet = parentSet;
 }
コード例 #3
0
 private UnaryArithmeticExpression(
     XCriteriaBuilder criteriaBuilder, Expression<? extends N> operand) {
   super(criteriaBuilder);
   Arguments.mustNotBeNull("operand", operand);
   this.mustUnderSameCriteriaBuilder("operand", operand);
   this.operand = operand;
 }
コード例 #4
0
ファイル: QueryPaths.java プロジェクト: ChenArthur/babyfish
 @Override
 public Builder get(
     String nodeName, GetterType getterType, CollectionFetchType collectionFetchType) {
   Arguments.mustNotBeEmpty("nodeName", Arguments.mustNotBeNull("nodeName", nodeName));
   Arguments.mustNotBeNull("getterType", getterType);
   Arguments.mustNotBeNull("collectionFetchType", collectionFetchType);
   Object[] arr = this.arr;
   int len = this.len;
   if (len + 3 > arr.length) {
     Object[] newArr = new Object[len << 1];
     System.arraycopy(arr, 0, newArr, 0, len);
     this.arr = arr = newArr;
   }
   arr[len] = nodeName;
   arr[len + 1] = getterType;
   arr[len + 2] = collectionFetchType;
   this.len += 3;
   return this;
 }
コード例 #5
0
 protected FrozenLazyInitializerImpl(HibernateProxy owner) {
   ProxyObject proxyObject = (ProxyObject) owner;
   MethodHandler handler = proxyObject.getHandler();
   if (!(handler instanceof LazyInitializer)) {
     Arguments.mustBeInstanceOfValue(
         "((" + ProxyObject.class.getName() + ")owner).getHandler()",
         handler,
         LazyInitializer.class);
   }
   Class<?> persistentClass = getPersistentClass((BasicLazyInitializer) handler);
   LazyInitializer lazyInitializer = owner.getHibernateLazyInitializer();
   if (lazyInitializer instanceof FrozenLazyInitializer) {
     throw new AssertionError();
   }
   this.owner = owner;
   this.lazyInitializer = lazyInitializer;
   this.objectModelMetadata = HibernateMetadatas.of(persistentClass);
   this.initTransient(persistentClass);
   proxyObject.setHandler(this);
 }
コード例 #6
0
 protected SqlAwareDriver(Driver targetDriver) {
   this.targetDriver = Arguments.mustNotBeNull("targetDriver", targetDriver);
 }
コード例 #7
0
ファイル: XQueryImpl.java プロジェクト: ChenArthur/babyfish
 @Override
 public XQuery setQueryType(QueryType queryType) {
   Arguments.mustNotBeNull("queryType", queryType);
   this.queryType = queryType;
   return this;
 }