Skip to content
GitLab
Projects
Groups
Topics
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
TFS
controller
Compare revisions
8cd8e0d960c7d0ed2e8e6a1c9aa0faddd397f02c...6c4ef63c949dafdaf42da6b0a121983820e0c3f8
Hide whitespace changes
Inline
Side-by-side
Some changes are not shown.
For a faster browsing experience, only
20 of 406+
files are shown. Download one of the files below to see all changes.
src/automation/src/main/java/eu/teraflow/automation/context/ContextService.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context
;
import
eu.teraflow.automation.context.model.Device
;
import
eu.teraflow.automation.context.model.DeviceEvent
;
import
io.smallrye.mutiny.Multi
;
import
io.smallrye.mutiny.Uni
;
public
interface
ContextService
{
Uni
<
Device
>
getDevice
(
String
deviceId
);
Multi
<
DeviceEvent
>
getDeviceEvents
();
}
src/automation/src/main/java/eu/teraflow/automation/context/ContextServiceImpl.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context
;
import
eu.teraflow.automation.context.model.Device
;
import
eu.teraflow.automation.context.model.DeviceEvent
;
import
io.smallrye.mutiny.Multi
;
import
io.smallrye.mutiny.Uni
;
import
javax.enterprise.context.ApplicationScoped
;
import
javax.inject.Inject
;
@ApplicationScoped
public
class
ContextServiceImpl
implements
ContextService
{
private
final
ContextGateway
contextGateway
;
@Inject
public
ContextServiceImpl
(
ContextGateway
contextGateway
)
{
this
.
contextGateway
=
contextGateway
;
}
@Override
public
Uni
<
Device
>
getDevice
(
String
deviceId
)
{
return
contextGateway
.
getDevice
(
deviceId
);
}
@Override
public
Multi
<
DeviceEvent
>
getDeviceEvents
()
{
return
contextGateway
.
getDeviceEvents
();
}
}
src/automation/src/main/java/eu/teraflow/automation/context/model/ConfigActionEnum.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
public
enum
ConfigActionEnum
{
UNDEFINED
,
SET
,
DELETE
}
src/automation/src/main/java/eu/teraflow/automation/context/model/ConfigRule.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
public
class
ConfigRule
{
private
final
ConfigActionEnum
configActionEnum
;
private
final
ConfigRuleType
<?>
configRuleType
;
public
ConfigRule
(
ConfigActionEnum
configActionEnum
,
ConfigRuleType
<?>
configRuleType
)
{
this
.
configActionEnum
=
configActionEnum
;
this
.
configRuleType
=
configRuleType
;
}
public
ConfigActionEnum
getConfigActionEnum
()
{
return
configActionEnum
;
}
public
ConfigRuleType
getConfigRuleType
()
{
return
configRuleType
;
}
@Override
public
String
toString
()
{
return
String
.
format
(
"%s:{configActionEnum:\"%s\", %s}"
,
getClass
().
getSimpleName
(),
configActionEnum
,
configRuleType
);
}
}
src/automation/src/main/java/eu/teraflow/automation/context/model/ConfigRuleAcl.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
import
eu.teraflow.automation.acl.AclRuleSet
;
public
class
ConfigRuleAcl
{
private
final
EndPointId
endPointId
;
private
final
AclRuleSet
ruleSet
;
public
ConfigRuleAcl
(
EndPointId
endPointId
,
AclRuleSet
ruleSet
)
{
this
.
endPointId
=
endPointId
;
this
.
ruleSet
=
ruleSet
;
}
public
EndPointId
getEndPointId
()
{
return
endPointId
;
}
public
AclRuleSet
getRuleSet
()
{
return
ruleSet
;
}
@Override
public
String
toString
()
{
return
String
.
format
(
"%s:{%s, %s}"
,
getClass
().
getSimpleName
(),
endPointId
,
ruleSet
);
}
}
src/automation/src/main/java/eu/teraflow/automation/context/model/ConfigRuleCustom.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
public
class
ConfigRuleCustom
{
private
final
String
resourceKey
;
private
final
String
resourceValue
;
public
ConfigRuleCustom
(
String
resourceKey
,
String
resourceValue
)
{
this
.
resourceKey
=
resourceKey
;
this
.
resourceValue
=
resourceValue
;
}
public
String
getResourceKey
()
{
return
resourceKey
;
}
public
String
getResourceValue
()
{
return
resourceValue
;
}
@Override
public
String
toString
()
{
return
String
.
format
(
"%s:{%s, %s}"
,
getClass
().
getSimpleName
(),
resourceKey
,
resourceValue
);
}
}
src/automation/src/main/java/eu/teraflow/automation/context/model/ConfigRuleType.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
public
interface
ConfigRuleType
<
T
>
{
public
T
getConfigRuleType
();
}
src/automation/src/main/java/eu/teraflow/automation/context/model/ConfigRuleTypeAcl.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
public
class
ConfigRuleTypeAcl
implements
ConfigRuleType
<
ConfigRuleAcl
>
{
private
final
ConfigRuleAcl
configRuleAcl
;
public
ConfigRuleTypeAcl
(
ConfigRuleAcl
configRuleAcl
)
{
this
.
configRuleAcl
=
configRuleAcl
;
}
@Override
public
ConfigRuleAcl
getConfigRuleType
()
{
return
this
.
configRuleAcl
;
}
@Override
public
String
toString
()
{
return
String
.
format
(
"%s:%s}"
,
getClass
().
getSimpleName
(),
configRuleAcl
);
}
}
src/automation/src/main/java/eu/teraflow/automation/context/model/ConfigRuleTypeCustom.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
public
class
ConfigRuleTypeCustom
implements
ConfigRuleType
<
ConfigRuleCustom
>
{
private
final
ConfigRuleCustom
configRuleCustom
;
public
ConfigRuleTypeCustom
(
ConfigRuleCustom
configRuleCustom
)
{
this
.
configRuleCustom
=
configRuleCustom
;
}
@Override
public
ConfigRuleCustom
getConfigRuleType
()
{
return
this
.
configRuleCustom
;
}
@Override
public
String
toString
()
{
return
String
.
format
(
"%s:%s}"
,
getClass
().
getSimpleName
(),
configRuleCustom
);
}
}
src/automation/src/main/java/eu/teraflow/automation/context/model/Device.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
import
eu.teraflow.automation.common.Util
;
import
java.util.List
;
public
class
Device
{
private
final
String
deviceId
;
private
final
String
deviceName
;
private
final
String
deviceType
;
private
DeviceConfig
deviceConfig
;
private
DeviceOperationalStatus
deviceOperationalStatus
;
private
List
<
DeviceDriverEnum
>
deviceDrivers
;
private
List
<
EndPoint
>
endPoints
;
public
Device
(
String
deviceId
,
String
deviceName
,
String
deviceType
,
DeviceConfig
deviceConfig
,
DeviceOperationalStatus
deviceOperationalStatus
,
List
<
DeviceDriverEnum
>
deviceDrivers
,
List
<
EndPoint
>
endPoints
)
{
this
.
deviceId
=
deviceId
;
this
.
deviceName
=
deviceName
;
this
.
deviceType
=
deviceType
;
this
.
deviceConfig
=
deviceConfig
;
this
.
deviceOperationalStatus
=
deviceOperationalStatus
;
this
.
deviceDrivers
=
deviceDrivers
;
this
.
endPoints
=
endPoints
;
}
public
Device
(
String
deviceId
,
String
deviceName
,
String
deviceType
,
DeviceOperationalStatus
deviceOperationalStatus
,
List
<
DeviceDriverEnum
>
deviceDrivers
,
List
<
EndPoint
>
endPoints
)
{
this
.
deviceId
=
deviceId
;
this
.
deviceName
=
deviceName
;
this
.
deviceType
=
deviceType
;
this
.
deviceOperationalStatus
=
deviceOperationalStatus
;
this
.
deviceDrivers
=
deviceDrivers
;
this
.
endPoints
=
endPoints
;
}
public
boolean
isEnabled
()
{
return
deviceOperationalStatus
==
DeviceOperationalStatus
.
ENABLED
;
}
public
boolean
isDisabled
()
{
return
deviceOperationalStatus
==
DeviceOperationalStatus
.
DISABLED
;
}
public
void
enableDevice
()
{
this
.
deviceOperationalStatus
=
DeviceOperationalStatus
.
ENABLED
;
}
public
void
disableDevice
()
{
this
.
deviceOperationalStatus
=
DeviceOperationalStatus
.
DISABLED
;
}
public
String
getDeviceId
()
{
return
deviceId
;
}
public
String
getDeviceName
()
{
return
deviceName
;
}
public
String
getDeviceType
()
{
return
deviceType
;
}
public
DeviceConfig
getDeviceConfig
()
{
return
deviceConfig
;
}
public
List
<
DeviceDriverEnum
>
getDeviceDrivers
()
{
return
deviceDrivers
;
}
public
List
<
EndPoint
>
getEndPoints
()
{
return
endPoints
;
}
public
DeviceOperationalStatus
getDeviceOperationalStatus
()
{
return
deviceOperationalStatus
;
}
public
void
setDeviceConfiguration
(
DeviceConfig
deviceConfig
)
{
this
.
deviceConfig
=
deviceConfig
;
}
@Override
public
String
toString
()
{
return
String
.
format
(
"%s:{deviceId:\"%s\", deviceName:\"%s\", deviceType:\"%s\", %s, deviceOperationalStatus=\"%s\", [%s], [%s]}"
,
getClass
().
getSimpleName
(),
deviceId
,
deviceName
,
deviceType
,
deviceConfig
,
deviceOperationalStatus
.
toString
(),
Util
.
toString
(
deviceDrivers
),
Util
.
toString
(
endPoints
));
}
}
src/automation/src/main/java/eu/teraflow/automation/context/model/DeviceConfig.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
import
java.util.List
;
import
java.util.stream.Collectors
;
public
class
DeviceConfig
{
private
final
List
<
ConfigRule
>
configRules
;
public
DeviceConfig
(
List
<
ConfigRule
>
configRules
)
{
this
.
configRules
=
configRules
;
}
public
List
<
ConfigRule
>
getConfigRules
()
{
return
configRules
;
}
@Override
public
String
toString
()
{
final
var
configRulesDescription
=
configRules
.
stream
().
map
(
ConfigRule:
:
toString
).
collect
(
Collectors
.
joining
(
", "
));
return
String
.
format
(
"%s[%s]"
,
getClass
().
getSimpleName
(),
configRulesDescription
);
}
}
src/automation/src/main/java/eu/teraflow/automation/context/model/DeviceDriverEnum.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
public
enum
DeviceDriverEnum
{
UNDEFINED
,
OPENCONFIG
,
TRANSPORT_API
,
P4
,
IETF_NETWORK_TOPOLOGY
,
ONF_TR_352
,
XR
,
IETF_L2VPN
}
src/automation/src/main/java/eu/teraflow/automation/context/model/DeviceOperationalStatus.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
public
enum
DeviceOperationalStatus
{
UNDEFINED
,
DISABLED
,
ENABLED
}
src/automation/src/main/java/eu/teraflow/automation/context/model/Empty.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
public
class
Empty
{
public
Empty
()
{
// Empty constructor to represent the Empty rpc message of context service
}
}
src/automation/src/main/java/eu/teraflow/automation/context/model/EndPoint.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
import
eu.teraflow.automation.common.Util
;
import
eu.teraflow.automation.kpi_sample_types.model.KpiSampleType
;
import
java.util.List
;
public
class
EndPoint
{
private
final
EndPointId
endPointId
;
private
final
String
endPointType
;
private
final
List
<
KpiSampleType
>
kpiSampleTypes
;
private
final
Location
endPointLocation
;
EndPoint
(
EndPointBuilder
builder
)
{
this
.
endPointId
=
builder
.
endPointId
;
this
.
endPointType
=
builder
.
endPointType
;
this
.
kpiSampleTypes
=
builder
.
kpiSampleTypes
;
this
.
endPointLocation
=
builder
.
endPointLocation
;
}
public
EndPointId
getEndPointId
()
{
return
endPointId
;
}
public
String
getEndPointType
()
{
return
endPointType
;
}
public
List
<
KpiSampleType
>
getKpiSampleTypes
()
{
return
kpiSampleTypes
;
}
public
Location
getEndPointLocation
()
{
return
endPointLocation
;
}
@Override
public
String
toString
()
{
return
String
.
format
(
"%s:{%s, endPointType:\"%s\", [%s], %s}"
,
getClass
().
getSimpleName
(),
endPointId
,
endPointType
,
Util
.
toString
(
kpiSampleTypes
),
endPointLocation
);
}
public
static
class
EndPointBuilder
{
private
final
EndPointId
endPointId
;
private
final
String
endPointType
;
private
final
List
<
KpiSampleType
>
kpiSampleTypes
;
private
Location
endPointLocation
;
public
EndPointBuilder
(
EndPointId
endPointId
,
String
endPointType
,
List
<
KpiSampleType
>
kpiSampleTypes
)
{
this
.
endPointId
=
endPointId
;
this
.
endPointType
=
endPointType
;
this
.
kpiSampleTypes
=
kpiSampleTypes
;
}
public
EndPointBuilder
location
(
Location
endPointLocation
)
{
this
.
endPointLocation
=
endPointLocation
;
return
this
;
}
public
EndPoint
build
()
{
EndPoint
endPoint
=
new
EndPoint
(
this
);
validateEndPointObject
(
endPoint
);
return
endPoint
;
}
private
void
validateEndPointObject
(
EndPoint
endPoint
)
{
final
var
validatedEndPointId
=
endPoint
.
getEndPointId
();
final
var
validatedEndPointType
=
endPoint
.
getEndPointType
();
final
var
validatedKpiSampleTypes
=
endPoint
.
getKpiSampleTypes
();
if
(
validatedEndPointId
==
null
)
{
throw
new
IllegalStateException
(
"EndPoint ID cannot be null"
);
}
if
(
validatedEndPointType
==
null
)
{
throw
new
IllegalStateException
(
"EndPoint type cannot be null"
);
}
if
(
validatedKpiSampleTypes
==
null
)
{
throw
new
IllegalStateException
(
"Kpi sample types cannot be null"
);
}
}
}
}
src/automation/src/main/java/eu/teraflow/automation/context/model/EndPointId.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
public
class
EndPointId
{
private
final
TopologyId
topologyId
;
private
final
String
deviceId
;
private
final
String
id
;
public
EndPointId
(
TopologyId
topologyId
,
String
deviceId
,
String
id
)
{
this
.
topologyId
=
topologyId
;
this
.
deviceId
=
deviceId
;
this
.
id
=
id
;
}
public
TopologyId
getTopologyId
()
{
return
topologyId
;
}
public
String
getDeviceId
()
{
return
deviceId
;
}
public
String
getId
()
{
return
id
;
}
@Override
public
String
toString
()
{
return
String
.
format
(
"%s:{%s, deviceId:\"%s\", id:\"%s\"}"
,
getClass
().
getSimpleName
(),
topologyId
,
deviceId
,
id
);
}
}
src/automation/src/main/java/eu/teraflow/automation/context/model/Event.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
public
class
Event
{
// TODO convert double to meaningful timestamp type
private
final
double
timestamp
;
private
final
EventTypeEnum
eventType
;
public
Event
(
double
timestamp
,
EventTypeEnum
eventType
)
{
this
.
timestamp
=
timestamp
;
this
.
eventType
=
eventType
;
}
public
double
getTimestamp
()
{
return
timestamp
;
}
public
EventTypeEnum
getEventTypeEnum
()
{
return
eventType
;
}
@Override
public
String
toString
()
{
return
String
.
format
(
"%s{timestamp=\"%f\", eventType=\"%s\"}"
,
getClass
().
getSimpleName
(),
timestamp
,
eventType
.
toString
());
}
}
src/automation/src/main/java/eu/teraflow/automation/context/model/EventTypeEnum.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
public
enum
EventTypeEnum
{
UNDEFINED
,
CREATE
,
UPDATE
,
REMOVE
}
src/automation/src/main/java/eu/teraflow/automation/context/model/GpsPosition.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
public
class
GpsPosition
{
private
final
float
latitude
;
private
final
float
longitude
;
public
GpsPosition
(
float
latitude
,
float
longitude
)
{
this
.
latitude
=
latitude
;
this
.
longitude
=
longitude
;
}
public
float
getLatitude
()
{
return
latitude
;
}
public
float
getLongitude
()
{
return
longitude
;
}
@Override
public
String
toString
()
{
return
String
.
format
(
"%s:{latitude:\"%f\", longitude:\"%f\"}"
,
getClass
().
getSimpleName
(),
latitude
,
longitude
);
}
}
src/automation/src/main/java/eu/teraflow/automation/context/model/Location.java
deleted
100644 → 0
View file @
8cd8e0d9
/*
* Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package
eu.teraflow.automation.context.model
;
public
class
Location
{
private
final
LocationType
<?>
locationType
;
public
Location
(
LocationType
<?>
locationType
)
{
this
.
locationType
=
locationType
;
}
public
LocationType
getLocationType
()
{
return
locationType
;
}
@Override
public
String
toString
()
{
return
String
.
format
(
"%s:{%s}"
,
getClass
().
getSimpleName
(),
locationType
);
}
}
Prev
1
…
10
11
12
13
14
15
16
17
18
…
21
Next