public ChainedProperty < S > trim ( ) { if ( getChainCount ( ) == 0 ) { throw new IllegalStateException ( ) ; } if ( getChainCount ( ) == 1 ) { if ( ! isOuterJoin ( 0 ) ) { return get ( mPrime ) ; } else { return get ( mPrime , null , new boolean [ ] { true } ) ; } } StorableProperty < ? > [ ] newChain = new StorableProperty [ getChainCount ( ) - 1 ] ; System . arraycopy ( mChain , 0 , newChain , 0 , newChain . length ) ; boolean [ ] newOuterJoin = mOuterJoin ; if ( newOuterJoin != null && newOuterJoin . length > ( newChain . length + 1 ) ) { newOuterJoin = new boolean [ newChain . length + 1 ] ; System . arraycopy ( mOuterJoin , 0 , newOuterJoin , 0 , newChain . length + 1 ) ; } return get ( mPrime , newChain , newOuterJoin ) ; }
Returns a new ChainedProperty with the last property in the chain removed .