コード例 #1
0
ファイル: OrbitModel.java プロジェクト: openxal/openxal
 /**
  * Get the flattener.
  *
  * @return a new flattener
  */
 public Flattener getFlattener() {
   if (_flattener == null) {
     _flattener = new Flattener(this);
     _modificationStore.postModification(this);
   }
   return _flattener;
 }
コード例 #2
0
ファイル: OrbitModel.java プロジェクト: openxal/openxal
  /**
   * Set the selected sequence
   *
   * @param sequence the new selected sequence
   */
  public void setSequence(final AcceleratorSeq sequence) {
    _sequence = sequence;

    // clear the probe since a new one will need to be made for the new sequence
    _baseProbe = null;

    loadBPMs();
    loadCorrectors();
    useSetpoints(sequence);

    BEAM_EXCURSION_ORBIT_ADAPTOR.setSequence(sequence);
    BEAM_EXCURSION_ORBIT_ADAPTOR.setBPMAgents(_bpmAgents);

    synchronized (_orbitSources) {
      for (final OrbitSource orbitSource : _orbitSources) {
        orbitSource.setSequence(sequence, _bpmAgents);
      }
    }

    _modificationStore.postModification(this);
    EVENT_PROXY.sequenceChanged(this, sequence);
  }
コード例 #3
0
ファイル: OrbitModel.java プロジェクト: openxal/openxal
 /** mark the model as having a modification */
 public void postModification() {
   _modificationStore.postModification(this);
 }