WireCurrentsCollection
A collection of wire currents results.
Example
app = pf.GetApplication() app:NewProject() app:OpenFile(FEKO_HOME..[[/shared/Resources/Automation/Dipole_Example_MultipleCurrents.fek]]) -- Obtain the collection of wire currents in the model currents = app.Models[1].Configurations[1].WireCurrents -- Display the list of current requests print("The following current requests are available:") printlist(currents) -- Export each of the currents to a file for i, currentData in pairs(currents) do print("Exporting " .. currentData.Label) filename = "temp_CurrentsFor" .. currentData.Label currentData:ExportData(filename, pf.Enums.CurrentsExportTypeEnum.Currents, 2) end
Usage locations
The WireCurrentsCollection object can be accessed from the following locations:
- Collection lists
- SolutionConfiguration object has collection WireCurrents.
Property List
Method List
- Contains (label string)
- Checks if the collection contains an item with the given label. (Returns a boolean object.)
- Item (index number)
- Returns the WireCurrentsData at the given index. (Returns a WireCurrentsData object.)
- Item (label string)
- Returns the WireCurrentsData with the given label. (Returns a WireCurrentsData object.)
- Items ()
- Returns a table of WireCurrentsData. (Returns a List of WireCurrentsData object.)
- UniqueName (label string)
- Generates a unique name base of of the provided base name.If the base name already exists in the collection, a digit will be appended until a valid name is generated. (Returns a boolean object.)
Index List
- [number]
- Returns the WireCurrentsData at the given index in the collection. (Read WireCurrentsData)
- [string]
- Returns the WireCurrentsData with the given name in the collection. (Read WireCurrentsData)
Property Details
Method Details
- Contains (label string)
- Checks if the collection contains an item with the given label.
- Item (index number)
- Returns the WireCurrentsData at the given index.
- Input Parameters
- index(number)
- The index of the WireCurrentsData.
- Return
- WireCurrentsData
- The WireCurrentsData at the given index.
- Item (label string)
- Returns the WireCurrentsData with the given label.
- Input Parameters
- label(string)
- The label of the WireCurrentsData.
- Return
- WireCurrentsData
- The WireCurrentsData with the given label.
- Items ()
- Returns a table of WireCurrentsData.
- Return
- List of WireCurrentsData
- A table of WireCurrentsData.
- UniqueName (label string)
- Generates a unique name base of of the provided base name.If the base name already exists in the collection, a digit will be appended until a valid name is generated.