@@ -44,30 +44,29 @@ public enum Type {
4444 }
4545
4646 private final Type type ;
47- private final String functionDefinition ;
47+ private final String content ;
4848
49- UserDefinedFunction (Type type , String functionDefinition ) {
49+ UserDefinedFunction (Type type , String content ) {
5050 this .type = type ;
51- this .functionDefinition = functionDefinition ;
51+ this .content = content ;
5252 }
5353
5454 public Type type () {
5555 return type ;
5656 }
5757
5858 /**
59- * Returns function's definition. If {@link #type()} is {@link Type#INLINE} this method returns
60- * a code blob. If {@link #type()} is {@link Type#FROM_URI} this method returns a Google Cloud
61- * Storage URI (e.g. gs://bucket/path).
59+ * If {@link #type()} is {@link Type#INLINE} this method returns a code blob. If {@link #type()}
60+ * is {@link Type#FROM_URI} the method returns a Google Cloud Storage URI (e.g. gs://bucket/path).
6261 */
63- public String functionDefinition () {
64- return functionDefinition ;
62+ public String content () {
63+ return content ;
6564 }
6665
6766 /**
6867 * A Google Cloud BigQuery user-defined function, as a code blob.
6968 */
70- public static final class InlineFunction extends UserDefinedFunction {
69+ static final class InlineFunction extends UserDefinedFunction {
7170
7271 private static final long serialVersionUID = 1083672109192091686L ;
7372
@@ -77,20 +76,20 @@ public static final class InlineFunction extends UserDefinedFunction {
7776
7877 @ Override
7978 public String toString () {
80- return MoreObjects .toStringHelper (this ).add ("inlineCode" , functionDefinition ()).toString ();
79+ return MoreObjects .toStringHelper (this ).add ("inlineCode" , content ()).toString ();
8180 }
8281
8382 @ Override
8483 public com .google .api .services .bigquery .model .UserDefinedFunctionResource toPb () {
8584 return new com .google .api .services .bigquery .model .UserDefinedFunctionResource ()
86- .setInlineCode (functionDefinition ());
85+ .setInlineCode (content ());
8786 }
8887 }
8988
9089 /**
9190 * A Google Cloud BigQuery user-defined function, as an URI to Google Cloud Storage.
9291 */
93- public static final class UriFunction extends UserDefinedFunction {
92+ static final class UriFunction extends UserDefinedFunction {
9493
9594 private static final long serialVersionUID = 4660331691852223839L ;
9695
@@ -100,19 +99,19 @@ public static final class UriFunction extends UserDefinedFunction {
10099
101100 @ Override
102101 public String toString () {
103- return MoreObjects .toStringHelper (this ).add ("functionUri" , functionDefinition ()).toString ();
102+ return MoreObjects .toStringHelper (this ).add ("functionUri" , content ()).toString ();
104103 }
105104
106105 @ Override
107106 public com .google .api .services .bigquery .model .UserDefinedFunctionResource toPb () {
108107 return new com .google .api .services .bigquery .model .UserDefinedFunctionResource ()
109- .setResourceUri (functionDefinition ());
108+ .setResourceUri (content ());
110109 }
111110 }
112111
113112 @ Override
114113 public int hashCode () {
115- return Objects .hash (type , functionDefinition );
114+ return Objects .hash (type , content );
116115 }
117116
118117 @ Override
0 commit comments