code
stringlengths 23
201k
| docstring
stringlengths 17
96.2k
| func_name
stringlengths 0
235
| language
stringclasses 1
value | repo
stringlengths 8
72
| path
stringlengths 11
317
| url
stringlengths 57
377
| license
stringclasses 7
values |
|---|---|---|---|---|---|---|---|
public static <V> Iterator<V> concat(Iterator<V>... iterators) {
if (iterators.length == 1) {
return iterators[0];
} else {
IteratorStack<V> stack = new IteratorStack<V>();
for (Iterator<V> it : iterators) {
stack.addLast(it);
}
return stack;
}
}
|
@param iterators a list of iterators
@return a concatenation of all iterators, in the order provided
|
concat
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/Iterators.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/Iterators.java
|
MIT
|
public static <V> Iterator<V> drop(Iterator<V> it, long n) {
for (long i = 0; i < n && it.hasNext(); i++) {
it.next();
}
return it;
}
|
@param it an iterator
@param n the number of elements to drop, which may be larger than the number of values in the iterator
@return an iterator with the first {@code n} values dropped
|
drop
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/Iterators.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/Iterators.java
|
MIT
|
public static <V> Stream<V> toStream(Iterator<V> it) {
return toStream(it, 0);
}
|
@param it an iterator
@param n the number of elements to drop, which may be larger than the number of values in the iterator
@return an iterator with the first {@code n} values dropped
|
toStream
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/Iterators.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/Iterators.java
|
MIT
|
public static <V> Stream<V> toStream(Iterator<V> it, long estimatedSize) {
return StreamSupport.stream(Spliterators.spliterator(it, estimatedSize, Spliterator.ORDERED), false);
}
|
@param it an iterator
@param n the number of elements to drop, which may be larger than the number of values in the iterator
@return an iterator with the first {@code n} values dropped
|
toStream
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/Iterators.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/Iterators.java
|
MIT
|
@Override
public String toString() {
return index + ": " + value;
}
|
@param it an iterator
@param n the number of elements to drop, which may be larger than the number of values in the iterator
@return an iterator with the first {@code n} values dropped
|
toString
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/Iterators.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/Iterators.java
|
MIT
|
public static <V> Iterator<Indexed<V>> indexed(Iterator<V> it) {
return indexed(it, 0);
}
|
@param it an iterator
@param n the number of elements to drop, which may be larger than the number of values in the iterator
@return an iterator with the first {@code n} values dropped
|
indexed
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/Iterators.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/Iterators.java
|
MIT
|
public static <V> Iterator<Indexed<V>> indexed(Iterator<V> it, long offset) {
AtomicLong counter = new AtomicLong(offset);
return map(it, v -> new Indexed<>(counter.getAndIncrement(), v));
}
|
@param it an iterator
@param n the number of elements to drop, which may be larger than the number of values in the iterator
@return an iterator with the first {@code n} values dropped
|
indexed
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/Iterators.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/Iterators.java
|
MIT
|
public static byte[] from(CharSequence cs) {
return from(cs, 0, cs.length());
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
from
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static byte[] from(CharSequence cs, int start, int end) {
if (end - start > 255) {
throw new IllegalArgumentException("cannot encode a block of more than 255 UTF-16 code units");
}
int numBytes = 0;
int numCodePoints = 0;
for (int charIdx = start; charIdx < end; numCodePoints++) {
char c = cs.charAt(charIdx);
if (isHighSurrogate(c)) {
numBytes += 4;
charIdx += 2;
} else {
numBytes += encodedLength(c & 0xFFFF);
charIdx += 1;
}
}
byte[] chunk = new byte[numBytes + 2];
chunk[0] = (byte) numCodePoints;
chunk[1] = (byte) (end - start);
for (int charIdx = start, offset = 2; charIdx < end; ) {
char c = cs.charAt(charIdx);
int codePoint;
if (isHighSurrogate(c)) {
codePoint = Character.toCodePoint(c, cs.charAt(charIdx + 1));
charIdx += 2;
} else {
codePoint = c & 0xFFFF;
charIdx += 1;
}
numBytes += encodedLength(codePoint);
offset += overwrite(chunk, offset, codePoint);
}
return chunk;
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
from
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static CharSequence toCharSequence(byte[] chunk) {
return new CharSequence() {
@Override
public int length() {
return numCodeUnits(chunk);
}
@Override
public char charAt(int index) {
return nthUnit(chunk, index);
}
@Override
public CharSequence subSequence(int start, int end) {
return CharSequences.subSequence(this, start, end);
}
@Override
public String toString() {
return UnicodeChunk.toString(chunk);
}
};
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
toCharSequence
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
@Override
public int length() {
return numCodeUnits(chunk);
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
length
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
@Override
public char charAt(int index) {
return nthUnit(chunk, index);
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
charAt
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
@Override
public CharSequence subSequence(int start, int end) {
return CharSequences.subSequence(this, start, end);
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
subSequence
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
@Override
public String toString() {
return UnicodeChunk.toString(chunk);
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
toString
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static String toString(byte[] chunk) {
char[] cs = new char[numCodeUnits(chunk)];
for (int bi = 2, ci = 0; ci < cs.length; ) {
int codePoint = decode(chunk, bi);
bi += codePoint < 0x80 ? 1 : prefixLength(chunk[bi]);
if (isBmpCodePoint(codePoint)) {
cs[ci++] = (char) codePoint;
} else {
cs[ci++] = highSurrogate(codePoint);
cs[ci++] = lowSurrogate(codePoint);
}
}
return new String(cs);
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
toString
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static byte[] concat(byte[] a, byte[] b) {
if (numCodeUnits(a) + numCodeUnits(b) > 255) {
throw new IllegalArgumentException("cannot create a chunk larger than 255 UTF-16 code units");
}
byte[] newChunk = new byte[a.length + b.length - 2];
arraycopy(a, 2, newChunk, 2, a.length - 2);
arraycopy(b, 2, newChunk, a.length, b.length - 2);
newChunk[0] = (byte) (numCodePoints(a) + numCodePoints(b));
newChunk[1] = (byte) (numCodeUnits(a) + numCodeUnits(b));
return newChunk;
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
concat
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static byte[] insert(byte[] a, byte[] b, int idx) {
if (numCodeUnits(a) + numCodeUnits(b) > 255) {
throw new IllegalArgumentException("cannot create a chunk larger than 255 UTF-16 code units");
}
int offset = offset(a, idx);
byte[] newChunk = new byte[a.length + b.length - 2];
arraycopy(a, 2, newChunk, 2, offset - 2);
arraycopy(b, 2, newChunk, offset, b.length - 2);
arraycopy(a, offset, newChunk, offset + b.length - 2, a.length - offset);
newChunk[0] = (byte) (numCodePoints(a) + numCodePoints(b));
newChunk[1] = (byte) (numCodeUnits(a) + numCodeUnits(b));
return newChunk;
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
insert
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static byte[] slice(byte[] chunk, int start, int end) {
if (start == end) {
return EMPTY;
} else if (start == 0 && end == numCodePoints(chunk)) {
return chunk;
}
int startOffset;
int codeUnits = 0;
int endOffset;
if (isAscii(chunk)) {
startOffset = start + 2;
endOffset = end + 2;
codeUnits = end - start;
} else {
startOffset = offset(chunk, start);
endOffset = startOffset;
for (int i = start; i < end; i++) {
byte b = chunk[endOffset];
int len = b >= 0 ? 1 : prefixLength(b);
codeUnits += len == 4 ? 2 : 1;
endOffset += len;
}
}
byte[] newChunk = new byte[(endOffset - startOffset) + 2];
arraycopy(chunk, startOffset, newChunk, 2, newChunk.length - 2);
newChunk[0] = (byte) (end - start);
newChunk[1] = (byte) codeUnits;
return newChunk;
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
slice
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static char nthUnit(byte[] chunk, int idx) {
if (isAscii(chunk)) {
return (char) chunk[idx + 2];
} else {
return findNthUnit(chunk, idx);
}
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
nthUnit
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static int nthPoint(byte[] chunk, int idx) {
return decode(chunk, offset(chunk, idx));
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
nthPoint
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static int numCodePoints(byte[] chunk) {
return chunk[0] & 0xFF;
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
numCodePoints
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static int numCodeUnits(byte[] chunk) {
return chunk[1] & 0xFF;
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
numCodeUnits
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static OfInt codePointIterator(byte[] chunk) {
return new OfInt() {
private int idx = 2;
@Override
public int nextInt() {
int codePoint = decode(chunk, idx);
idx += prefixLength(chunk[idx]);
return codePoint;
}
@Override
public boolean hasNext() {
return idx < chunk.length;
}
};
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
codePointIterator
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
@Override
public int nextInt() {
int codePoint = decode(chunk, idx);
idx += prefixLength(chunk[idx]);
return codePoint;
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
nextInt
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
@Override
public boolean hasNext() {
return idx < chunk.length;
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
hasNext
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static OfInt reverseCodePointIterator(byte[] chunk) {
return new OfInt() {
int idx = chunk.length;
@Override
public int nextInt() {
while ((chunk[idx] & 0b11000000) == 0b10000000) {
idx--;
}
int codePoint = decode(chunk, idx);
idx--;
return codePoint;
}
@Override
public boolean hasNext() {
return idx > 2;
}
};
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
reverseCodePointIterator
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
@Override
public int nextInt() {
while ((chunk[idx] & 0b11000000) == 0b10000000) {
idx--;
}
int codePoint = decode(chunk, idx);
idx--;
return codePoint;
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
nextInt
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
@Override
public boolean hasNext() {
return idx > 2;
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
hasNext
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static OfInt codeUnitIterator(byte[] chunk) {
return new OfInt() {
OfInt it = codePointIterator(chunk);
short low = -1;
@Override
public int nextInt() {
if (low == -1) {
int codePoint = it.nextInt();
if (codePoint < 0x10000) {
return codePoint;
} else {
low = (short) Character.lowSurrogate(codePoint);
return Character.highSurrogate(codePoint);
}
} else {
int val = low;
low = -1;
return val;
}
}
@Override
public boolean hasNext() {
return low != -1 || it.hasNext();
}
};
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
codeUnitIterator
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
@Override
public int nextInt() {
if (low == -1) {
int codePoint = it.nextInt();
if (codePoint < 0x10000) {
return codePoint;
} else {
low = (short) Character.lowSurrogate(codePoint);
return Character.highSurrogate(codePoint);
}
} else {
int val = low;
low = -1;
return val;
}
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
nextInt
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
@Override
public boolean hasNext() {
return low != -1 || it.hasNext();
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
hasNext
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static OfInt reverseCodeUnitIterator(byte[] chunk) {
return new OfInt() {
OfInt it = codePointIterator(chunk);
short high = -1;
@Override
public int nextInt() {
if (high == -1) {
int codePoint = it.nextInt();
if (codePoint < 0x10000) {
return codePoint;
} else {
high = (short) Character.highSurrogate(codePoint);
return Character.lowSurrogate(codePoint);
}
} else {
int val = high;
high = -1;
return val;
}
}
@Override
public boolean hasNext() {
return high != -1 || it.hasNext();
}
};
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
reverseCodeUnitIterator
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
@Override
public int nextInt() {
if (high == -1) {
int codePoint = it.nextInt();
if (codePoint < 0x10000) {
return codePoint;
} else {
high = (short) Character.highSurrogate(codePoint);
return Character.lowSurrogate(codePoint);
}
} else {
int val = high;
high = -1;
return val;
}
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
nextInt
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
@Override
public boolean hasNext() {
return high != -1 || it.hasNext();
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
hasNext
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static int writeCodeUnits(char[] array, int offset, byte[] chunk) {
for (int aryIdx = offset, chunkIdx = 2; chunkIdx < chunk.length; ) {
byte b = chunk[chunkIdx];
if (b >= 0) {
array[aryIdx++] = (char) b;
chunkIdx++;
} else {
int codePoint = decode(chunk, chunkIdx);
chunkIdx += encodedLength(codePoint);
if (isBmpCodePoint(codePoint)) {
array[aryIdx++] = (char) codePoint;
} else {
array[aryIdx++] = highSurrogate(codePoint);
array[aryIdx++] = lowSurrogate(codePoint);
}
}
}
return numCodeUnits(chunk);
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
writeCodeUnits
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static int writeCodePoints(int[] array, int offset, byte[] chunk) {
for (int aryIdx = offset, chunkIdx = 2; chunkIdx < chunk.length; ) {
int codePoint = decode(chunk, chunkIdx);
array[aryIdx++] = codePoint;
chunkIdx += encodedLength(codePoint);
}
return numCodePoints(chunk);
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
writeCodePoints
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
private static char findNthUnit(byte[] chunk, int idx) {
int offset = 2;
for (; ; ) {
if (idx == 0) {
int point = decode(chunk, offset);
return isBmpCodePoint(point) ? (char) point : highSurrogate(point);
}
byte b = chunk[offset];
if (b >= 0) {
idx--;
offset++;
} else {
int len = prefixLength(b);
int codeUnits = 1 << (len >> 2);
idx -= codeUnits;
if (idx < 0) {
return lowSurrogate(decode(chunk, offset));
}
offset += len;
}
}
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
findNthUnit
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
private static int offset(byte[] chunk, int idx) {
if (isAscii(chunk)) {
return idx + 2;
} else {
return findNthPoint(chunk, idx);
}
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
offset
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
private static int findNthPoint(byte[] chunk, int idx) {
int offset = 2;
while (idx-- > 0) {
byte b = chunk[offset];
if (b >= 0) {
offset++;
} else {
offset += prefixLength(b);
}
}
return offset;
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
findNthPoint
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
private static boolean isAscii(byte[] chunk) {
return (chunk[0] & 0xFF) == (chunk.length - 2);
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
isAscii
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
private static int encodedLength(int codePoint) {
if (codePoint < 0x80) {
return 1;
} else if (codePoint < 0x800) {
return 2;
} else if (codePoint < 0x10000) {
return 3;
} else {
return 4;
}
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
encodedLength
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
private static int overwrite(byte[] chunk, int offset, int codePoint) {
if (codePoint < 0x80) {
chunk[offset] = (byte) codePoint;
return 1;
} else {
return overwriteMultibyte(chunk, offset, codePoint);
}
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
overwrite
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
private static int overwriteMultibyte(byte[] chunk, final int offset, int codePoint) {
final int length;
final int mask;
if (codePoint < 0x800) {
length = 2;
mask = 0b11000000;
} else if (codePoint < 0x10000) {
length = 3;
mask = 0b11100000;
} else {
length = 4;
mask = 0b11110000;
}
for (int i = offset + length - 1; i > offset; i--) {
chunk[i] = (byte) ((codePoint & 0b00111111) | 0b10000000);
codePoint >>= 6;
}
chunk[offset] = (byte) (codePoint | mask);
return length;
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
overwriteMultibyte
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
public static int prefixLength(byte prefix) {
return LENGTHS[(prefix & 0xFF) >> 3];
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
prefixLength
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
private static int decode(byte[] array, int offset) {
byte b = array[offset];
if (b >= 0) {
return b;
}
int len = prefixLength(b);
int codePoint = b & ((1 << (7 - len)) - 1);
for (int i = offset + 1; i < offset + len; i++) {
codePoint = (codePoint << 6) | (array[i] & 0b00111111);
}
return codePoint;
}
|
An immutable UTF-8 encoded block of no more than 255 UTF-16 code units, which allows lookups by both code point and
code unit.
|
decode
|
java
|
lacuna/bifurcan
|
src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
https://github.com/lacuna/bifurcan/blob/master/src/io/lacuna/bifurcan/utils/UnicodeChunk.java
|
MIT
|
@Override
public void registerBeanDefinitions(AnnotationMetadata importingClassMetadata, BeanDefinitionRegistry registry) {
if (!AutoConfigurationPackages.has(this.beanFactory)) {
logger.debug("Could not determine auto-configuration package, automatic mapper scanning disabled.");
return;
}
logger.debug("Searching for mappers annotated with @Mapper");
List<String> packages = AutoConfigurationPackages.get(this.beanFactory);
if (logger.isDebugEnabled()) {
packages.forEach(pkg -> logger.debug("Using auto-configuration base package '{}'", pkg));
}
BeanDefinitionBuilder builder = BeanDefinitionBuilder.genericBeanDefinition(MapperScannerConfigurer.class);
builder.addPropertyValue("processPropertyPlaceHolders", true);
builder.addPropertyValue("annotationClass", Mapper.class);
builder.addPropertyValue("basePackage", StringUtils.collectionToCommaDelimitedString(packages));
BeanWrapper beanWrapper = new BeanWrapperImpl(MapperScannerConfigurer.class);
Set<String> propertyNames = Stream.of(beanWrapper.getPropertyDescriptors()).map(PropertyDescriptor::getName)
.collect(Collectors.toSet());
if (propertyNames.contains("lazyInitialization")) {
// Need to mybatis-spring 2.0.2+
builder.addPropertyValue("lazyInitialization", "${mybatis.lazy-initialization:false}");
}
if (propertyNames.contains("defaultScope")) {
// Need to mybatis-spring 2.0.6+
builder.addPropertyValue("defaultScope", "${mybatis.mapper-default-scope:}");
}
// for spring-native
boolean injectSqlSession = environment.getProperty("mybatis.inject-sql-session-on-mapper-scan", Boolean.class,
Boolean.TRUE);
if (injectSqlSession && this.beanFactory instanceof ListableBeanFactory) {
ListableBeanFactory listableBeanFactory = (ListableBeanFactory) this.beanFactory;
Optional<String> sqlSessionTemplateBeanName = Optional
.ofNullable(getBeanNameForType(SqlSessionTemplate.class, listableBeanFactory));
Optional<String> sqlSessionFactoryBeanName = Optional
.ofNullable(getBeanNameForType(SqlSessionFactory.class, listableBeanFactory));
if (sqlSessionTemplateBeanName.isPresent() || !sqlSessionFactoryBeanName.isPresent()) {
builder.addPropertyValue("sqlSessionTemplateBeanName",
sqlSessionTemplateBeanName.orElse("sqlSessionTemplate"));
} else {
builder.addPropertyValue("sqlSessionFactoryBeanName", sqlSessionFactoryBeanName.orElseThrow());
}
}
builder.setRole(BeanDefinition.ROLE_INFRASTRUCTURE);
registry.registerBeanDefinition(MapperScannerConfigurer.class.getName(), builder.getBeanDefinition());
}
|
This will just scan the same base package as Spring Boot does. If you want more power, you can explicitly use
{@link org.mybatis.spring.annotation.MapperScan} but this will get typed mappers working correctly, out-of-the-box,
similar to using Spring Data JPA repositories.
|
registerBeanDefinitions
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.java
|
Apache-2.0
|
@Override
public void setBeanFactory(BeanFactory beanFactory) {
this.beanFactory = beanFactory;
}
|
This will just scan the same base package as Spring Boot does. If you want more power, you can explicitly use
{@link org.mybatis.spring.annotation.MapperScan} but this will get typed mappers working correctly, out-of-the-box,
similar to using Spring Data JPA repositories.
|
setBeanFactory
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.java
|
Apache-2.0
|
@Override
public void setEnvironment(Environment environment) {
this.environment = environment;
}
|
This will just scan the same base package as Spring Boot does. If you want more power, you can explicitly use
{@link org.mybatis.spring.annotation.MapperScan} but this will get typed mappers working correctly, out-of-the-box,
similar to using Spring Data JPA repositories.
|
setEnvironment
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.java
|
Apache-2.0
|
private String getBeanNameForType(Class<?> type, ListableBeanFactory factory) {
String[] beanNames = factory.getBeanNamesForType(type);
return beanNames.length > 0 ? beanNames[0] : null;
}
|
This will just scan the same base package as Spring Boot does. If you want more power, you can explicitly use
{@link org.mybatis.spring.annotation.MapperScan} but this will get typed mappers working correctly, out-of-the-box,
similar to using Spring Data JPA repositories.
|
getBeanNameForType
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.java
|
Apache-2.0
|
@Override
public void afterPropertiesSet() {
logger.debug(
"Not found configuration for registering mapper bean using @MapperScan, MapperFactoryBean and MapperScannerConfigurer.");
}
|
If mapper registering configuration or mapper scanning configuration not present, this configuration allow to scan
mappers based on the same component-scanning path as Spring Boot itself.
|
afterPropertiesSet
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.java
|
Apache-2.0
|
@Bean
@ConditionalOnMissingBean
FreeMarkerLanguageDriver freeMarkerLanguageDriver() {
return new FreeMarkerLanguageDriver();
}
|
Configuration class for mybatis-freemarker 1.1.x or under.
|
freeMarkerLanguageDriver
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
Apache-2.0
|
@Bean
@ConditionalOnMissingBean
FreeMarkerLanguageDriver freeMarkerLanguageDriver(FreeMarkerLanguageDriverConfig config) {
return new FreeMarkerLanguageDriver(config);
}
|
Configuration class for mybatis-freemarker 1.2.x or above.
|
freeMarkerLanguageDriver
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
Apache-2.0
|
@Bean
@ConditionalOnMissingBean
@ConfigurationProperties(CONFIGURATION_PROPERTY_PREFIX + ".freemarker")
public FreeMarkerLanguageDriverConfig freeMarkerLanguageDriverConfig() {
return FreeMarkerLanguageDriverConfig.newInstance();
}
|
Configuration class for mybatis-freemarker 1.2.x or above.
|
freeMarkerLanguageDriverConfig
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
Apache-2.0
|
@Bean
@ConditionalOnMissingBean
org.mybatis.scripting.velocity.Driver velocityLanguageDriver() {
return new org.mybatis.scripting.velocity.Driver();
}
|
Configuration class for mybatis-velocity 2.0 or under.
|
velocityLanguageDriver
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
Apache-2.0
|
@Bean
@ConditionalOnMissingBean
VelocityLanguageDriver velocityLanguageDriver(VelocityLanguageDriverConfig config) {
return new VelocityLanguageDriver(config);
}
|
Configuration class for mybatis-velocity 2.1.x or above.
|
velocityLanguageDriver
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
Apache-2.0
|
@Bean
@ConditionalOnMissingBean
@ConfigurationProperties(CONFIGURATION_PROPERTY_PREFIX + ".velocity")
public VelocityLanguageDriverConfig velocityLanguageDriverConfig() {
return VelocityLanguageDriverConfig.newInstance();
}
|
Configuration class for mybatis-velocity 2.1.x or above.
|
velocityLanguageDriverConfig
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
Apache-2.0
|
@Bean
@ConditionalOnMissingBean
ThymeleafLanguageDriver thymeleafLanguageDriver(ThymeleafLanguageDriverConfig config) {
return new ThymeleafLanguageDriver(config);
}
|
Configuration class for mybatis-velocity 2.1.x or above.
|
thymeleafLanguageDriver
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
Apache-2.0
|
@Bean
@ConditionalOnMissingBean
@ConfigurationProperties(CONFIGURATION_PROPERTY_PREFIX + ".thymeleaf")
public ThymeleafLanguageDriverConfig thymeleafLanguageDriverConfig() {
return ThymeleafLanguageDriverConfig.newInstance();
}
|
Configuration class for mybatis-velocity 2.1.x or above.
|
thymeleafLanguageDriverConfig
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
Apache-2.0
|
@ConfigurationProperties(CONFIGURATION_PROPERTY_PREFIX + ".thymeleaf.dialect")
@Override
public DialectConfig getDialect() {
return super.getDialect();
}
|
Configuration class for mybatis-velocity 2.1.x or above.
|
getDialect
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
Apache-2.0
|
@ConfigurationProperties(CONFIGURATION_PROPERTY_PREFIX + ".thymeleaf.template-file")
@Override
public TemplateFileConfig getTemplateFile() {
return super.getTemplateFile();
}
|
Configuration class for mybatis-velocity 2.1.x or above.
|
getTemplateFile
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisLanguageDriverAutoConfiguration.java
|
Apache-2.0
|
public Boolean getSafeRowBoundsEnabled() {
return safeRowBoundsEnabled;
}
|
Specifies the database identify value for switching query to use.
|
getSafeRowBoundsEnabled
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setSafeRowBoundsEnabled(Boolean safeRowBoundsEnabled) {
this.safeRowBoundsEnabled = safeRowBoundsEnabled;
}
|
Specifies the database identify value for switching query to use.
|
setSafeRowBoundsEnabled
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Boolean getSafeResultHandlerEnabled() {
return safeResultHandlerEnabled;
}
|
Specifies the database identify value for switching query to use.
|
getSafeResultHandlerEnabled
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setSafeResultHandlerEnabled(Boolean safeResultHandlerEnabled) {
this.safeResultHandlerEnabled = safeResultHandlerEnabled;
}
|
Specifies the database identify value for switching query to use.
|
setSafeResultHandlerEnabled
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Boolean getMapUnderscoreToCamelCase() {
return mapUnderscoreToCamelCase;
}
|
Specifies the database identify value for switching query to use.
|
getMapUnderscoreToCamelCase
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setMapUnderscoreToCamelCase(Boolean mapUnderscoreToCamelCase) {
this.mapUnderscoreToCamelCase = mapUnderscoreToCamelCase;
}
|
Specifies the database identify value for switching query to use.
|
setMapUnderscoreToCamelCase
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Boolean getAggressiveLazyLoading() {
return aggressiveLazyLoading;
}
|
Specifies the database identify value for switching query to use.
|
getAggressiveLazyLoading
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setAggressiveLazyLoading(Boolean aggressiveLazyLoading) {
this.aggressiveLazyLoading = aggressiveLazyLoading;
}
|
Specifies the database identify value for switching query to use.
|
setAggressiveLazyLoading
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
@DeprecatedConfigurationProperty(since = "3.0.4", reason = "The option is not used at MyBatis core module. It will be removed in the future. See https://github.com/mybatis/mybatis-3/pull/3238")
public Boolean getMultipleResultSetsEnabled() {
return multipleResultSetsEnabled;
}
|
Specifies the database identify value for switching query to use.
|
getMultipleResultSetsEnabled
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setMultipleResultSetsEnabled(Boolean multipleResultSetsEnabled) {
this.multipleResultSetsEnabled = multipleResultSetsEnabled;
}
|
Specifies the database identify value for switching query to use.
|
setMultipleResultSetsEnabled
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Boolean getUseGeneratedKeys() {
return useGeneratedKeys;
}
|
Specifies the database identify value for switching query to use.
|
getUseGeneratedKeys
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setUseGeneratedKeys(Boolean useGeneratedKeys) {
this.useGeneratedKeys = useGeneratedKeys;
}
|
Specifies the database identify value for switching query to use.
|
setUseGeneratedKeys
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Boolean getUseColumnLabel() {
return useColumnLabel;
}
|
Specifies the database identify value for switching query to use.
|
getUseColumnLabel
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setUseColumnLabel(Boolean useColumnLabel) {
this.useColumnLabel = useColumnLabel;
}
|
Specifies the database identify value for switching query to use.
|
setUseColumnLabel
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Boolean getCacheEnabled() {
return cacheEnabled;
}
|
Specifies the database identify value for switching query to use.
|
getCacheEnabled
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setCacheEnabled(Boolean cacheEnabled) {
this.cacheEnabled = cacheEnabled;
}
|
Specifies the database identify value for switching query to use.
|
setCacheEnabled
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Boolean getCallSettersOnNulls() {
return callSettersOnNulls;
}
|
Specifies the database identify value for switching query to use.
|
getCallSettersOnNulls
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setCallSettersOnNulls(Boolean callSettersOnNulls) {
this.callSettersOnNulls = callSettersOnNulls;
}
|
Specifies the database identify value for switching query to use.
|
setCallSettersOnNulls
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Boolean getUseActualParamName() {
return useActualParamName;
}
|
Specifies the database identify value for switching query to use.
|
getUseActualParamName
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setUseActualParamName(Boolean useActualParamName) {
this.useActualParamName = useActualParamName;
}
|
Specifies the database identify value for switching query to use.
|
setUseActualParamName
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Boolean getReturnInstanceForEmptyRow() {
return returnInstanceForEmptyRow;
}
|
Specifies the database identify value for switching query to use.
|
getReturnInstanceForEmptyRow
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setReturnInstanceForEmptyRow(Boolean returnInstanceForEmptyRow) {
this.returnInstanceForEmptyRow = returnInstanceForEmptyRow;
}
|
Specifies the database identify value for switching query to use.
|
setReturnInstanceForEmptyRow
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Boolean getShrinkWhitespacesInSql() {
return shrinkWhitespacesInSql;
}
|
Specifies the database identify value for switching query to use.
|
getShrinkWhitespacesInSql
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setShrinkWhitespacesInSql(Boolean shrinkWhitespacesInSql) {
this.shrinkWhitespacesInSql = shrinkWhitespacesInSql;
}
|
Specifies the database identify value for switching query to use.
|
setShrinkWhitespacesInSql
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Boolean getNullableOnForEach() {
return nullableOnForEach;
}
|
Specifies the database identify value for switching query to use.
|
getNullableOnForEach
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setNullableOnForEach(Boolean nullableOnForEach) {
this.nullableOnForEach = nullableOnForEach;
}
|
Specifies the database identify value for switching query to use.
|
setNullableOnForEach
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Boolean getArgNameBasedConstructorAutoMapping() {
return argNameBasedConstructorAutoMapping;
}
|
Specifies the database identify value for switching query to use.
|
getArgNameBasedConstructorAutoMapping
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setArgNameBasedConstructorAutoMapping(Boolean argNameBasedConstructorAutoMapping) {
this.argNameBasedConstructorAutoMapping = argNameBasedConstructorAutoMapping;
}
|
Specifies the database identify value for switching query to use.
|
setArgNameBasedConstructorAutoMapping
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public String getLogPrefix() {
return logPrefix;
}
|
Specifies the database identify value for switching query to use.
|
getLogPrefix
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setLogPrefix(String logPrefix) {
this.logPrefix = logPrefix;
}
|
Specifies the database identify value for switching query to use.
|
setLogPrefix
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Class<? extends Log> getLogImpl() {
return logImpl;
}
|
Specifies the database identify value for switching query to use.
|
getLogImpl
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setLogImpl(Class<? extends Log> logImpl) {
this.logImpl = logImpl;
}
|
Specifies the database identify value for switching query to use.
|
setLogImpl
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Class<? extends VFS> getVfsImpl() {
return vfsImpl;
}
|
Specifies the database identify value for switching query to use.
|
getVfsImpl
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setVfsImpl(Class<? extends VFS> vfsImpl) {
this.vfsImpl = vfsImpl;
}
|
Specifies the database identify value for switching query to use.
|
setVfsImpl
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public Class<?> getDefaultSqlProviderType() {
return defaultSqlProviderType;
}
|
Specifies the database identify value for switching query to use.
|
getDefaultSqlProviderType
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setDefaultSqlProviderType(Class<?> defaultSqlProviderType) {
this.defaultSqlProviderType = defaultSqlProviderType;
}
|
Specifies the database identify value for switching query to use.
|
setDefaultSqlProviderType
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public LocalCacheScope getLocalCacheScope() {
return localCacheScope;
}
|
Specifies the database identify value for switching query to use.
|
getLocalCacheScope
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setLocalCacheScope(LocalCacheScope localCacheScope) {
this.localCacheScope = localCacheScope;
}
|
Specifies the database identify value for switching query to use.
|
setLocalCacheScope
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public JdbcType getJdbcTypeForNull() {
return jdbcTypeForNull;
}
|
Specifies the database identify value for switching query to use.
|
getJdbcTypeForNull
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
public void setJdbcTypeForNull(JdbcType jdbcTypeForNull) {
this.jdbcTypeForNull = jdbcTypeForNull;
}
|
Specifies the database identify value for switching query to use.
|
setJdbcTypeForNull
|
java
|
mybatis/spring-boot-starter
|
mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
https://github.com/mybatis/spring-boot-starter/blob/master/mybatis-spring-boot-autoconfigure/src/main/java/org/mybatis/spring/boot/autoconfigure/MybatisProperties.java
|
Apache-2.0
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.