Interface SclEditor
- All Known Implementing Classes:
SclService
public interface SclEditor
Service class that will be used to create, update or delete elements in
SCL
XML Files.
The following features are supported:
- Initialization functions
Initialize the SCL object
Adds History object under THeader reference object
Update Header reference object
- IED features
- Communication features
- DAI features
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addHistoryItem
(SCL scd, String who, String what, String why) Adds new HistoryItem in SCL filevoid
Adds IED in SCL file (Related DataTypeTemplate of SCL is updated also)void
addSubnetworks
(SCL scd, List<SubNetworkDTO> subNetworks, SCL icd) Adds new SubNetworks in SCL file from ICD filevoid
importSTDElementsInSCD
(SCL scd, List<SCL> stds, List<SubNetworkTypeDTO> subNetworkTypes) Imports IEDs, DataTypeTemplates and Communication nodes of STD files into SCL (SCD) file STD : System Template Definition To import STD into SCD, this step are realized Check SCD and STD compatibilities by checking if there is at least one ICD_SYSTEM_VERSION_UUID in LNode/Private CompasICDHeader of SCL/Substation/..Initialise SCD file with Header and Private SCLFileTypemanageMonitoringLns
(SCL scd) Update and/or create Monitoring LNs (LSVS and LGOS) for bound GOOSE and SMV Control Blocksvoid
updateDAI
(SCL scd, String iedName, String ldInst, DataAttributeRef dataAttributeRef) Updates DAI based on given data in dataAttributeRefupdateDoInRef
(SCL scd) Update DAIs of DO InRef in all LN0 of the SCD using matching ExtRef information.void
updateHeader
(@NonNull SCL scd, @NonNull HeaderDTO headerDTO) Updates Header of SCL fileupdateLDeviceStatus
(SCL scd) Activate used LDevice and Deactivate unused LDevice inTLNode
-
Method Details
-
initScl
Initialise SCD file with Header and Private SCLFileType- Parameters:
hId
- SCL Header IDhVersion
- SCL Header VersionhRevision
- SCL Header Revision- Returns:
- SCL SCD object
- Throws:
ScdException
- throws when inconsistance in SCL file
-
addHistoryItem
Adds new HistoryItem in SCL file- Parameters:
scd
- SCL file in which new History should be addedwho
- Who realize the actionwhat
- What kind of action is realizedwhy
- Why this action is done
-
updateHeader
Updates Header of SCL file- Parameters:
scd
- SCL file in which Header should be updatedheaderDTO
- Header new values
-
addIED
Adds IED in SCL file (Related DataTypeTemplate of SCL is updated also)- Parameters:
scd
- SCL file in which IED should be addediedName
- name of IED to add in SCLicd
- ICD containing IED to add and related DataTypeTemplate- Throws:
ScdException
- throws when inconsistency between IED to add and SCL file content
-
addSubnetworks
Adds new SubNetworks in SCL file from ICD file- Parameters:
scd
- SCL file in which SubNetworks should be addedsubNetworks
- List of SubNetworks DTO contenting SubNetwork and ConnectedAp parameter namesicd
- ICD file from which SubNetworks functional data are copied from- Throws:
ScdException
- throws when no Communication in SCL and createIfNotExists == false
-
updateDAI
void updateDAI(SCL scd, String iedName, String ldInst, DataAttributeRef dataAttributeRef) throws ScdException Updates DAI based on given data in dataAttributeRef- Parameters:
scd
- SCL file in which DataTypeTemplate of DAI should be foundiedName
- name of IED in which DAI is localizedldInst
- ldInst of LDevice in which DAI is localizeddataAttributeRef
- reference summarized DataTypeTemplate related to DAI to update- Throws:
ScdException
- when inconsistency are found in th SCL's DataTypeTemplate. Which should normally not happens.
-
importSTDElementsInSCD
void importSTDElementsInSCD(SCL scd, List<SCL> stds, List<SubNetworkTypeDTO> subNetworkTypes) throws ScdException Imports IEDs, DataTypeTemplates and Communication nodes of STD files into SCL (SCD) file STD : System Template Definition To import STD into SCD, this step are realized- Check SCD and STD compatibilities by checking if there is at least one ICD_SYSTEM_VERSION_UUID in LNode/Private CompasICDHeader of SCL/Substation/.. not present in IED/Private CompasICDHeader of STD
- List all LNode/Private COMPAS-ICDHeader of SCL/Substation/.. and remove duplicated one with same iedName in order to ovoid repetition in actions
- For each Private.ICDSystemVersionUUID and Private.iedName in Substation/ of SCL find corresponding STD File
- import /IED /DataTypeTemplate from that STD file and update IEDName of /IED in SCD file
- import connectedAP and rename ConnectedAP/@iedName in Communication node in SCD file
- Parameters:
scd
- SCL object in which content of STD files are importedstds
- list of STD files contenting datas to import into SCDsubNetworkTypes
- couple of Subnetwork name and possible corresponding ConnectedAP names- Throws:
ScdException
- throws when inconsistency between Substation of SCL content and gien STD files as :- ICD_SYSTEM_VERSION_UUID in IED/Private of STD is not present in COMPAS-ICDHeader in Substation/../LNode of SCL
- There are several STD files corresponding to ICD_SYSTEM_VERSION_UUID of COMPAS-ICDHeader in Substation/../LNode of SCL
- There is no STD file found corresponding to COMPAS-ICDHeader in Substation/../LNode of SCL
- COMPAS-ICDHeader is not the same in Substation/../LNode of SCL and in IED/Private of STD
- COMPAS_ICDHEADER in Substation/../LNode of SCL not found in IED/Private of STD
-
updateLDeviceStatus
Activate used LDevice and Deactivate unused LDevice inTLNode
- Parameters:
scd
- SCL file for which LDevice should be activated or deactivated- Returns:
- list of encountered errors
-
updateDoInRef
Update DAIs of DO InRef in all LN0 of the SCD using matching ExtRef information.- Parameters:
scd
- SCL file for which DOs InRef should be updated with matching ExtRef information- Returns:
- list of encountered errors
-
manageMonitoringLns
Update and/or create Monitoring LNs (LSVS and LGOS) for bound GOOSE and SMV Control Blocks- Parameters:
scd
- SCL file for which LNs (LSVS and LGOS) should be updated and/or created in each LDevice LDSUIED with matching ExtRef information- Returns:
- list of encountered errors
-