@@ -74,10 +74,11 @@ static List<CelFunctionBinding> create() {
7474 }
7575
7676 /**
77- * This implementes that standard {@code bytes_to_string} function. We override it because the CEL
77+ * This implements that standard {@code bytes_to_string} function. We override it because the CEL
7878 * library doesn't validate that the bytes are valid utf-8.
7979 *
80- * <p>Workround until https://github.com/google/cel-java/pull/717 lands.
80+ * <p>Workaround until <a href="https://github.com/google/cel-java/pull/717">cel-java issue
81+ * 717</a> lands.
8182 */
8283 private static CelFunctionBinding celBytesToString () {
8384 return CelFunctionBinding .from (
@@ -202,9 +203,7 @@ private static CelFunctionBinding celContainsBytes() {
202203 "contains_bytes" ,
203204 ByteString .class ,
204205 ByteString .class ,
205- (receiver , param ) -> {
206- return bytesContains (receiver .toByteArray (), param .toByteArray ());
207- });
206+ (receiver , param ) -> bytesContains (receiver .toByteArray (), param .toByteArray ()));
208207 }
209208
210209 static boolean bytesContains (byte [] arr , byte [] subArr ) {
@@ -285,9 +284,7 @@ private static CelFunctionBinding celIsIpPrefixInt() {
285284 "is_ip_prefix_int" ,
286285 String .class ,
287286 Long .class ,
288- (prefix , version ) -> {
289- return isIpPrefix (prefix , version , false );
290- });
287+ (prefix , version ) -> isIpPrefix (prefix , version , false ));
291288 }
292289
293290 /**
@@ -300,9 +297,7 @@ private static CelFunctionBinding celIsIpPrefixBool() {
300297 "is_ip_prefix_bool" ,
301298 String .class ,
302299 Boolean .class ,
303- (prefix , strict ) -> {
304- return isIpPrefix (prefix , 0L , strict );
305- });
300+ (prefix , strict ) -> isIpPrefix (prefix , 0L , strict ));
306301 }
307302
308303 /**
@@ -390,9 +385,9 @@ private static CelFunctionBinding celIsHostAndPort() {
390385 * <p>The host can be one of:
391386 *
392387 * <ul>
393- * <li>An IPv4 address in dotted decimal format, for example " 192.168.0.1" .
394- * <li>An IPv6 address enclosed in square brackets, for example " [::1]" .
395- * <li>A hostname, for example " example.com" .
388+ * <li>An IPv4 address in dotted decimal format, for example {@code 192.168.0.1} .
389+ * <li>An IPv6 address enclosed in square brackets, for example {@code [::1]} .
390+ * <li>A hostname, for example {@code example.com} .
396391 * </ul>
397392 *
398393 * <p>The port is separated by a colon. It must be non-empty, with a decimal number in the range
@@ -570,7 +565,8 @@ static boolean isIp(String addr, long ver) {
570565 }
571566
572567 /**
573- * Returns true if the string is a URI, for example "https://example.com/foo/bar?baz=quux#frag".
568+ * Returns true if the string is a URI, for example {@code
569+ * https://example.com/foo/bar?baz=quux#frag}.
574570 *
575571 * <p>URI is defined in the internet standard RFC 3986. Zone Identifiers in IPv6 address literals
576572 * are supported (RFC 6874).
@@ -580,8 +576,9 @@ private static boolean isUri(String str) {
580576 }
581577
582578 /**
583- * Returns true if the string is a URI Reference - a URI such as
584- * "https://example.com/foo/bar?baz=quux#frag", or a Relative Reference such as "./foo/bar?query".
579+ * Returns true if the string is a URI Reference - a URI such as {@code
580+ * https://example.com/foo/bar?baz=quux#frag}, or a Relative Reference such as {@code
581+ * ./foo/bar?query}.
585582 *
586583 * <p>URI, URI Reference, and Relative Reference are defined in the internet standard RFC 3986.
587584 * Zone Identifiers in IPv6 address literals are supported (RFC 6874).
0 commit comments