Set the field that owns this listener.
@owner The field that this listener is being added to (if null, this listener is being removed).
335933
public void setOwner(ListenerOwner owner)
    {
        super.setOwner(owner);
        if (this.getOwner() != null)
            this.syncBehaviorToRecord(this.getOwner().getRecord().getField(m_iMainFilesFieldSeq));  // Init now
    }
111368
public void setOwner(ListenerOwner owner)
    {
        super.setOwner(owner);
        if (owner != null)
        {
            if (m_fldValue1 != null)
                if (m_fldValue1.getRecord() != this.getOwner().getRecord())
                    m_fldValue1.addListener(new FieldRemoveBOnCloseHandler(this));      // Not same file, if target file closes, remove this listener!
            if (m_fldValue2 != null)
                if (m_fldValue2.getRecord() != this.getOwner().getRecord())
                if (m_fldValue2.getRecord() != m_fldValue1.getRecord())
                    m_fldValue2.addListener(new FieldRemoveBOnCloseHandler(this));      // Not same file, if target file closes, remove this listener!
        }
    }
1364947
public void setOwner(ListenerOwner owner)
    {
        super.setOwner(owner);
        if (owner != null) if (this.getOwner().getState() == false)
            m_mergeRecord.getTable().removeTable(m_subRecord.getTable()); // If this is off initially, take the table out of the loop
    }
506197
public void setEnabled(boolean bEnableFlag)   // Init this field override for other value
    {
        if (m_fldTarget != null)
            m_fldTarget.setEnabled(bEnableFlag);
        else if (m_sField != null)
            m_sField.setEnabled(bEnableFlag);
        else
        {   // No field means enable/disable the key fields.
            Record table = this.getOwner();
            boolean bDisableOnFound = false;
            int iLastField = table.getFieldCount() + DBConstants.MAIN_FIELD - 1;
            for (int iFieldSeq = DBConstants.MAIN_FIELD; iFieldSeq <= iLastField; iFieldSeq++)
            {
                BaseField field = table.getField(iFieldSeq);
                BaseListener listener = field.getListener(MainReadOnlyHandler.class.getName());
                if (listener == null) // Don't touch if this has a read second listener on it!
                    field.setEnabled(bEnableFlag);
                if (field.getListener(DisableOnFieldHandler.class.getName()) != null)
                    bDisableOnFound = true;
            }
            if (bDisableOnFound)
            {   // These field listeners need to be notified that their fields have been enabled/disabled
                for (int iFieldSeq = DBConstants.MAIN_FIELD; iFieldSeq <= iLastField; iFieldSeq++)
                {
                    BaseField field = table.getField(iFieldSeq);
                    DisableOnFieldHandler listener = (DisableOnFieldHandler)field.getListener(DisableOnFieldHandler.class.getName());
                    if (listener != null)
                        listener.fieldChanged(DBConstants.DISPLAY, DBConstants.SCREEN_MOVE);    // I can do this because I know that this listener will not modify anything.
                }
                
            }
        }
    }
886297
public void addListener(FieldListener listener, BaseField field)
    {
        super.addListener(listener, field);
        if (listener.getOwner().getRecord() == this.getRecord())   // Only replicate listeners added to base.
        {
            Iterator<BaseTable> iterator = this.getTables();
            while (iterator.hasNext())
            {
                BaseTable table = iterator.next();
                if ((table != null) && (table != this.getNextTable()))
                {
                    BaseField fldInTable = table.getRecord().getField(field.getFieldName());
                    if (fldInTable != null)
                    {
                        FieldListener newBehavior = null; // Clone the file behaviors
                        try   {
                            newBehavior = (FieldListener)listener.clone(fldInTable);  // Clone the file behaviors
                        } catch (CloneNotSupportedException ex)   {
                            newBehavior = null;
                        }
                        if (newBehavior != null)
                            if (newBehavior.getOwner() == null)     // This should have been set, just being careful (ie., next line never called)
                                fldInTable.addListener(newBehavior);        // Add them to the new query
                    }
                }
            }
        }
    }
226747
@Override
  public void bind()
  {
    if (_ownerProvider == null) {
      _ownerBinding.bind();
      
      _ownerProvider = _ownerBinding.provider(); 

      _program = _manager.program(_method.getParameters());
    }
  }
765824
public void setDependentStateListener(BaseListener dependentStateListener)
    {
        if (!(dependentStateListener instanceof FieldListener))
            dependentStateListener = null;
        else if ((this.getOwner() == null)
            || (((FieldListener)dependentStateListener).getOwner() == null)
            || (this.getOwner().getRecord() != ((FieldListener)dependentStateListener).getOwner().getRecord()))
                dependentStateListener = null;
        super.setDependentStateListener(dependentStateListener);
    }
63385
public void setOwner(ListenerOwner owner)
    {
        if (owner == null)
        {
            if (m_messageListener != null)
            {
                m_messageListener.free();
                m_messageListener = null;
            }
        }
        super.setOwner(owner);
        if (owner != null)
        {
            Record record = this.getOwner().getRecord();
            MessageManager messageManager = ((Application)record.getTask().getApplication()).getMessageManager();
            if (messageManager != null)
            {
                BaseMessageFilter messageFilter = new BaseMessageFilter(MessageConstants.TRX_RETURN_QUEUE, MessageConstants.INTERNET_QUEUE, this, null);
                messageManager.addMessageFilter(messageFilter);
                m_messageListener = new  WaitForFieldChangeMessageListener(messageFilter, this);
                record.setupRecordListener(m_messageListener, false, false);   // I need to listen for record changes
            }
        }            
    }
1101045
public void setOwner(ListenerOwner owner)
    {
        super.setOwner(owner);
        if (owner != null) if (m_fldToDisable != null)
            if (this.getOwner().getRecord() != m_fldToDisable.getRecord())
                m_fldToDisable.addListener(new FieldRemoveBOnCloseHandler(this)); // Make sure you remove this listener if m_fldToDisable is gone.
        if (owner != null)
            if (m_fldToDisable == null)
                m_fldToDisable = this.getOwner();
        if (owner != null)
            this.fieldChanged(DBConstants.DONT_DISPLAY, DBConstants.INIT_MOVE);
        if (owner == null)
            m_fldToDisable.setEnabled(true);    // Remove the behavior = reenable the field
    }
17205
public static void setValue(Field field, Object self, Object value) {
        try {
            field.set(self, value);
        } catch (IllegalAccessException e) {
            throw ShedException.wrap(e, ShedErrorCode.UNABLE_TO_SET_FIELD)
                    .put("field", field.toGenericString());
        }
    }
677151
public void addListener(UserTransactionListener listener)
   {
      UserTransactionListenerImpl impl = new UserTransactionListenerImpl(listener);

      delegator.addListener(impl);
      listeners.put(listener, impl);
   }
626094
public void addListener(BaseListener listener)
    {
        listener.setNextListener(null);  // Just being safe
        if ((this.getRecord() != null) && (this.getRecord().getTable() != null))
            this.getRecord().getTable().addListener((FieldListener)listener, this);   // Give the table a chance to clone this or whatever.
        else
            this.doAddListener((FieldListener)listener);
    }
938497
function(field) {
    if (this.vars.hasOwnProperty(field)) {
      if (!this.usage.hasOwnProperty(field)) {
        this.usage[field] = 0;
      }
      this.usage[field]++;
    }
  }
1045331
public void setOwner(ListenerOwner owner)
    {
        super.setOwner(owner);
        if (owner != null) if (m_fldMain != null) if (m_fldMain.getRecord() != owner)
            m_fldMain.addListener(new FieldRemoveBOnCloseHandler(this));
    }
271358
public void doNewRecord(boolean bDisplayOption)
    {
        super.doNewRecord(bDisplayOption);
        BaseField fldTarget = null;
        if (typeFieldName != null)
            fldTarget = this.getOwner().getField(typeFieldName);
        else
            fldTarget = this.getOwner().getField(m_iTypeField);
        boolean[] rgbEnabled = fldTarget.setEnableListeners(false);
        InitOnceFieldHandler listener = (InitOnceFieldHandler)fldTarget.getListener(InitOnceFieldHandler.class.getName());
        if (listener != null)
            listener.setFirstTime(true);    // Special case - you shouldn't have put this listener here, but since you did...
        fldTarget.setValue(m_iTargetValue, DBConstants.DISPLAY, DBConstants.INIT_MOVE);
        fldTarget.setModified(false);
        fldTarget.setEnableListeners(rgbEnabled);
    }
59823
public void setOwner(ListenerOwner owner)
    {
        super.setOwner(owner);
        if (this.getOwner() != null)
        {
            if (m_fldTarget.getRecord() != this.getOwner().getRecord())
                m_fldTarget.getRecord().addListener(new FileRemoveBOnCloseHandler(this));   // Not same file, if target file closes, remove this listener!
        }
    }
1019158
public void setOwnerObject(GVRSceneObject owner) {
        if (owner != null)
        {
            if (getNative() != 0)
            {
                NativeComponent.setOwnerObject(getNative(), owner.getNative());
            }
            this.owner = owner;
            onAttach(owner);
        }
        else
        {
            if (null != this.owner) {
                onDetach(this.owner);
                if (getNative() != 0) {
                    NativeComponent.setOwnerObject(getNative(), 0L);
                }
                this.owner = null;
            }
        }
    }