MCPcopy Create free account
hub / github.com/grpc/grpc-java / endsWith

Method endsWith

netty/src/main/java/io/grpc/netty/Utils.java:231–243  ·  view source on GitHub ↗
(byte[] bytes, byte[] suffix)

Source from the content-addressed store, hash-verified

229 }
230
231 private static boolean endsWith(byte[] bytes, byte[] suffix) {
232 if (bytes == null || suffix == null || bytes.length < suffix.length) {
233 return false;
234 }
235
236 for (int i = 0; i < suffix.length; i++) {
237 if (bytes[bytes.length - suffix.length + i] != suffix[i]) {
238 return false;
239 }
240 }
241
242 return true;
243 }
244
245 public static boolean shouldRejectOnMetadataSizeSoftLimitExceeded(
246 int h2HeadersSize, int softLimitHeaderListSize, int maxHeaderListSize) {

Callers 15

checkLeakageMethod · 0.45
toHeadersMethod · 0.45
getStringMatcherMethod · 0.45
createMetadataProtoMethod · 0.45
toAddressMethod · 0.45
isServiceGlobMethod · 0.45
toStringMethod · 0.45
BinaryKeyMethod · 0.45

Calls

no outgoing calls