@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Need to preserve loggedInUser GenericUDFLoggedInUser other = (GenericUDFLoggedInUser) newInstance; if (this.loggedInUser != null) { other.loggedInUser = new Text(this.loggedInUser); } } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Need to preserve authorizer flag GenericUDFCurrentAuthorizer other = (GenericUDFCurrentAuthorizer) newInstance; if (this.authorizer != null) { other.authorizer = new Text(this.authorizer); } } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Need to preserve currentUser GenericUDFCurrentUser other = (GenericUDFCurrentUser) newInstance; if (this.currentUser != null) { other.currentUser = new Text(this.currentUser); } } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Need to preserve loggedInUser GenericUDFLoggedInUser other = (GenericUDFLoggedInUser) newInstance; if (this.loggedInUser != null) { other.loggedInUser = new Text(this.loggedInUser); } } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Need to preserve currentUser GenericUDFCurrentUser other = (GenericUDFCurrentUser) newInstance; if (this.currentUser != null) { other.currentUser = new Text(this.currentUser); } } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Need to preserve currentGroups GenericUDFCurrentGroups other = (GenericUDFCurrentGroups) newInstance; if (this.currentGroups != null) { if (currentGroups != null) { other.currentGroups = new ArrayList<Text>(); for (Text group : currentGroups) { other.currentGroups.add(new Text(group)); } } } } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Need to preserve currentDate GenericUDFCurrentDate other = (GenericUDFCurrentDate) newInstance; if (this.currentDate != null) { other.currentDate = new DateWritableV2(this.currentDate); } } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Need to preserve currentTimestamp GenericUDFCurrentTimestamp other = (GenericUDFCurrentTimestamp) newInstance; if (this.currentTimestamp != null) { other.currentTimestamp = new TimestampWritableV2(this.currentTimestamp); } } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Asserts the class invariant. (Same types.) GenericUDFInFile that = (GenericUDFInFile)newInstance; if (that != this) { that.set = (this.set == null ? null : (HashSet<String>)this.set.clone()); that.strObjectInspector = this.strObjectInspector; that.fileObjectInspector = this.fileObjectInspector; } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Asserts the class invariant. (Same types.) GenericUDFInFile that = (GenericUDFInFile)newInstance; if (that != this) { that.set = (this.set == null ? null : (HashSet<String>)this.set.clone()); that.strObjectInspector = this.strObjectInspector; that.fileObjectInspector = this.fileObjectInspector; } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Need to preserve currentTimestamp GenericUDFCurrentTimestamp other = (GenericUDFCurrentTimestamp) newInstance; if (this.currentTimestamp != null) { other.currentTimestamp = new TimestampWritable(this.currentTimestamp); } } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Need to preserve currentDate GenericUDFCurrentDate other = (GenericUDFCurrentDate) newInstance; if (this.currentDate != null) { other.currentDate = new DateWritable(this.currentDate); } } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Need to preserve enabled flag GenericUDFRestrictInformationSchema other = (GenericUDFRestrictInformationSchema) newInstance; if (this.enabled != null) { other.enabled = new BooleanWritable(this.enabled.get()); } } }
genericUDF.copyToNewInstance(clonedUDF); } catch (UDFArgumentException err) { throw new IllegalArgumentException(err);
genericUDF.copyToNewInstance(clonedUDF); } catch (UDFArgumentException err) { throw new IllegalArgumentException(err);
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Need to preserve currentUser GenericUDFCurrentUser other = (GenericUDFCurrentUser) newInstance; if (this.currentUser != null) { other.currentUser = new Text(this.currentUser); } } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Asserts the class invariant. (Same types.) GenericUDFInFile that = (GenericUDFInFile)newInstance; if (that != this) { that.set = (this.set == null ? null : (HashSet<String>)this.set.clone()); that.strObjectInspector = this.strObjectInspector; that.fileObjectInspector = this.fileObjectInspector; } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Need to preserve currentTimestamp GenericUDFCurrentTimestamp other = (GenericUDFCurrentTimestamp) newInstance; if (this.currentTimestamp != null) { other.currentTimestamp = new TimestampWritable(this.currentTimestamp); } } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); // Need to preserve currentDate GenericUDFCurrentDate other = (GenericUDFCurrentDate) newInstance; if (this.currentDate != null) { other.currentDate = new DateWritable(this.currentDate); } } }
@Override public void copyToNewInstance(Object newInstance) throws UDFArgumentException { super.copyToNewInstance(newInstance); if (_stdUdf == null) { return; } StdUdfWrapper newWrapper = (StdUdfWrapper) newInstance; newWrapper._inputObjectInspectors = _inputObjectInspectors; newWrapper._stdFactory = _stdFactory; newWrapper._stdUdf = _stdUdf; newWrapper._nullableArguments = _stdUdf.getAndCheckNullableArguments(); newWrapper._stdUdf.init(_stdFactory); newWrapper._requiredFilesProcessed = false; newWrapper.createStdData(); }