BornAgain  1.19.79
Simulate and fit neutron and x-ray scattering at grazing incidence
Interference2DLatticeItem Class Reference

Description

Definition at line 82 of file InterferenceItems.h.

Inheritance diagram for Interference2DLatticeItem:
[legend]
Collaboration diagram for Interference2DLatticeItem:
[legend]

Public Member Functions

 Interference2DLatticeItem ()
 
std::unique_ptr< IInterference > createInterference () const override
 
SelectionDescriptor< Profile2DItem * > decayFunction () const
 
SelectionDescriptor< Lattice2DItem * > latticeType () const
 
DoubleDescriptor positionVariance () const
 
void serialize (Streamer &s) override
 
void setDecayFunctionType (Profile2DItem *p)
 
void setLatticeType (Lattice2DItem *p)
 
void setXiIntegration (bool xiIntegration)
 
bool xiIntegration () const
 

Protected Attributes

SelectionProperty< Profile2DItem * > m_decayFunction
 
SelectionProperty< Lattice2DItem * > m_latticeType
 
DoubleProperty m_positionVariance
 
bool m_xiIntegration
 

Constructor & Destructor Documentation

◆ Interference2DLatticeItem()

Interference2DLatticeItem::Interference2DLatticeItem ( )

Definition at line 123 of file InterferenceItems.cpp.

125 {
127  "Decay Function", "Two-dimensional decay function (finite size effects)", "decay");
128 }
Interference2DAbstractLatticeItem(bool xiIntegration)
SelectionProperty< Profile2DItem * > m_decayFunction
void init(const QString &label, const QString &tooltip, const QString &persistentTag, ArgsForCreation... argsForCreation)
Initialize by means of a catalog class and optional creation arguments.

References SelectionProperty< T >::init(), and m_decayFunction.

Here is the call graph for this function:

Member Function Documentation

◆ createInterference()

std::unique_ptr< IInterference > Interference2DLatticeItem::createInterference ( ) const
overridevirtual

Implements InterferenceItem.

Definition at line 130 of file InterferenceItems.cpp.

131 {
132  Lattice2DItem* latticeItem = latticeType().currentItem();
133  std::unique_ptr<Interference2DLattice> result(
134  new Interference2DLattice(*latticeItem->createLattice()));
135 
136  result->setDecayFunction(*m_decayFunction->createProfile());
137  result->setIntegrationOverXi(xiIntegration());
138  result->setPositionVariance(positionVariance());
139 
140  return std::unique_ptr<IInterference>(result.release());
141 }
SelectionDescriptor< Lattice2DItem * > latticeType() const
DoubleDescriptor positionVariance() const
virtual std::unique_ptr< Lattice2D > createLattice() const =0
virtual std::unique_ptr< IProfile2D > createProfile() const =0

References Lattice2DItem::createLattice(), Profile2DItem::createProfile(), Interference2DAbstractLatticeItem::latticeType(), m_decayFunction, InterferenceItem::positionVariance(), and Interference2DAbstractLatticeItem::xiIntegration().

Here is the call graph for this function:

◆ decayFunction()

SelectionDescriptor< Profile2DItem * > Interference2DLatticeItem::decayFunction ( ) const

Definition at line 157 of file InterferenceItems.cpp.

158 {
159  return m_decayFunction;
160 }

References m_decayFunction.

◆ latticeType()

◆ positionVariance()

◆ serialize()

void Interference2DLatticeItem::serialize ( Streamer s)
overridevirtual

Implements InterferenceItem.

Definition at line 143 of file InterferenceItems.cpp.

144 {
145  s.assertVersion(0);
147  Serialize::rwValue(s, "integrate", m_xiIntegration);
148  Serialize::rwSelected<Lattice2DItemCatalog>(s, m_latticeType);
149  Serialize::rwSelected<Profile2DItemCatalog>(s, m_decayFunction);
150 }
void assertVersion(unsigned expectedVersion) const
As reader, throws DeserializationException unless the expected version is read. As writer,...
Definition: Streamer.cpp:26
void rwProperty(Streamer &s, DoubleProperty &d)
void rwValue(Streamer &s, const QString &tag, bool &val)
Definition: Serialize.cpp:19

References Streamer::assertVersion(), m_decayFunction, Interference2DAbstractLatticeItem::m_latticeType, InterferenceItem::m_positionVariance, Interference2DAbstractLatticeItem::m_xiIntegration, Serialize::rwProperty(), and Serialize::rwValue().

Here is the call graph for this function:

◆ setDecayFunctionType()

void Interference2DLatticeItem::setDecayFunctionType ( Profile2DItem p)

Definition at line 152 of file InterferenceItems.cpp.

153 {
154  m_decayFunction.set(p);
155 }
void set(T t, bool callInitializer=false)
Directly set the new item.

References m_decayFunction, and SelectionProperty< T >::set().

Here is the call graph for this function:

◆ setLatticeType()

void Interference2DAbstractLatticeItem::setLatticeType ( Lattice2DItem p)
inherited

Definition at line 99 of file InterferenceItems.cpp.

100 {
101  m_latticeType.set(p);
102 }

References Interference2DAbstractLatticeItem::m_latticeType, and SelectionProperty< T >::set().

Here is the call graph for this function:

◆ setXiIntegration()

void Interference2DAbstractLatticeItem::setXiIntegration ( bool  xiIntegration)
inherited

Definition at line 109 of file InterferenceItems.cpp.

110 {
112 }

References Interference2DAbstractLatticeItem::m_xiIntegration, and Interference2DAbstractLatticeItem::xiIntegration().

Referenced by SampleEditorController::setIntegrateOverXi().

Here is the call graph for this function:

◆ xiIntegration()

Member Data Documentation

◆ m_decayFunction

SelectionProperty<Profile2DItem*> Interference2DLatticeItem::m_decayFunction
protected

◆ m_latticeType

◆ m_positionVariance

◆ m_xiIntegration


The documentation for this class was generated from the following files: