This repository has been archived by the owner on May 7, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 782
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Class naming, pom.xml with tabs, separate bundles, ignore generated files, resolving MANIFEST conflict
- Loading branch information
1 parent
891c184
commit 810b1f8
Showing
22 changed files
with
300 additions
and
145 deletions.
There are no files selected for viewing
14 changes: 14 additions & 0 deletions
14
bundles/core/org.eclipse.smarthome.core.thing/ESH-INF/config/offsetProfile.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<config-description:config-descriptions | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xmlns:config-description="http://eclipse.org/smarthome/schemas/config-description/v1.0.0" | ||
xsi:schemaLocation="http://eclipse.org/smarthome/schemas/config-description/v1.0.0 | ||
http://eclipse.org/smarthome/schemas/config-description-1.0.0.xsd"> | ||
|
||
<config-description uri="profile:system:offset"> | ||
<parameter name="offset" type="text" required="true"> | ||
<label>Offset</label> | ||
<description>Offset (plain number or number with unit) to be applied on the state towards the item. The negative offset will be applied in the reverse direction.</description> | ||
</parameter> | ||
</config-description> | ||
</config-description:config-descriptions> |
40 changes: 40 additions & 0 deletions
40
...ore.thing/src/main/java/org/eclipse/smarthome/core/thing/profiles/dto/ProfileTypeDTO.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
/** | ||
* Copyright (c) 2014,2018 Contributors to the Eclipse Foundation | ||
* | ||
* See the NOTICE file(s) distributed with this work for additional | ||
* information regarding copyright ownership. | ||
* | ||
* This program and the accompanying materials are made available under the | ||
* terms of the Eclipse Public License 2.0 which is available at | ||
* http://www.eclipse.org/legal/epl-2.0 | ||
* | ||
* SPDX-License-Identifier: EPL-2.0 | ||
*/ | ||
package org.eclipse.smarthome.core.thing.profiles.dto; | ||
|
||
import java.util.Collection; | ||
|
||
/** | ||
* DTO for profile types | ||
* | ||
* @author Stefan Triller - initial contribution | ||
* | ||
*/ | ||
public class ProfileTypeDTO { | ||
|
||
public String uid; | ||
public String label; | ||
public String kind; | ||
public Collection<String> supportedItemTypes; | ||
|
||
public ProfileTypeDTO() { | ||
} | ||
|
||
public ProfileTypeDTO(String uid, String label, String kind, Collection<String> supportedItemTypes) { | ||
this.uid = uid; | ||
this.label = label; | ||
this.kind = kind; | ||
this.supportedItemTypes = supportedItemTypes; | ||
} | ||
|
||
} |
37 changes: 37 additions & 0 deletions
37
...ing/src/main/java/org/eclipse/smarthome/core/thing/profiles/dto/ProfileTypeDTOMapper.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
/** | ||
* Copyright (c) 2014,2018 Contributors to the Eclipse Foundation | ||
* | ||
* See the NOTICE file(s) distributed with this work for additional | ||
* information regarding copyright ownership. | ||
* | ||
* This program and the accompanying materials are made available under the | ||
* terms of the Eclipse Public License 2.0 which is available at | ||
* http://www.eclipse.org/legal/epl-2.0 | ||
* | ||
* SPDX-License-Identifier: EPL-2.0 | ||
*/ | ||
package org.eclipse.smarthome.core.thing.profiles.dto; | ||
|
||
import org.eclipse.smarthome.core.thing.profiles.ProfileType; | ||
import org.eclipse.smarthome.core.thing.profiles.TriggerProfileType; | ||
|
||
/** | ||
* The {@link ProfileTypeDTOMapper} is an utility class to map profile-types into profile-type data transfer | ||
* objects (DTOs). | ||
* | ||
* @author Stefan Triller - initial contribution | ||
* | ||
*/ | ||
public class ProfileTypeDTOMapper { | ||
|
||
/** | ||
* Maps profile type into stripped profile type data transfer object. | ||
* | ||
* @param profileType the profile type to be mapped | ||
* @return the profile type DTO object | ||
*/ | ||
public static ProfileTypeDTO map(ProfileType profileType) { | ||
return new ProfileTypeDTO(profileType.getUID().toString(), profileType.getLabel(), | ||
profileType instanceof TriggerProfileType ? "TRIGGER" : "STATE", profileType.getSupportedItemTypes()); | ||
} | ||
} |
175 changes: 88 additions & 87 deletions
175
bundles/core/org.eclipse.smarthome.core/META-INF/MANIFEST.MF
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,87 +1,88 @@ | ||
Manifest-Version: 1.0 | ||
Bundle-License: https://www.eclipse.org/legal/epl-2.0/ | ||
Bundle-ManifestVersion: 2 | ||
Bundle-Name: Eclipse SmartHome Core | ||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 | ||
Bundle-SymbolicName: org.eclipse.smarthome.core | ||
Bundle-Vendor: Eclipse.org/SmartHome | ||
Bundle-Version: 0.10.0.qualifier | ||
Export-Package: | ||
org.eclipse.smarthome.core.auth, | ||
org.eclipse.smarthome.core.auth.client.oauth2, | ||
org.eclipse.smarthome.core.binding, | ||
org.eclipse.smarthome.core.binding.dto, | ||
org.eclipse.smarthome.core.cache, | ||
org.eclipse.smarthome.core.common, | ||
org.eclipse.smarthome.core.common.osgi, | ||
org.eclipse.smarthome.core.common.registry, | ||
org.eclipse.smarthome.core.events;uses:="org.eclipse.smarthome.core.items,org.osgi.service.event,org.eclipse.smarthome.core.types", | ||
org.eclipse.smarthome.core.extension, | ||
org.eclipse.smarthome.core.i18n, | ||
org.eclipse.smarthome.core.items;uses:="org.eclipse.smarthome.core.types,org.eclipse.smarthome.core.events", | ||
org.eclipse.smarthome.core.items.dto, | ||
org.eclipse.smarthome.core.items.events, | ||
org.eclipse.smarthome.core.library, | ||
org.eclipse.smarthome.core.library.dimension, | ||
org.eclipse.smarthome.core.library.items, | ||
org.eclipse.smarthome.core.library.types, | ||
org.eclipse.smarthome.core.library.unit, | ||
org.eclipse.smarthome.core.net, | ||
org.eclipse.smarthome.core.scheduler, | ||
org.eclipse.smarthome.core.service, | ||
org.eclipse.smarthome.core.storage, | ||
org.eclipse.smarthome.core.types, | ||
org.eclipse.smarthome.core.types.util, | ||
org.eclipse.smarthome.core.util | ||
Ignore-Package: org.eclipse.smarthome.core.internal.items,org.eclipse.sm | ||
arthome.core.internal,org.eclipse.smarthome.core.internal.events,org.ec | ||
lipse.smarthome.core.internal.logging | ||
Import-Package: | ||
com.google.common.collect, | ||
com.google.gson, | ||
javax.measure, | ||
javax.measure.quantity, | ||
javax.measure.spi, | ||
org.apache.commons.io, | ||
org.apache.commons.lang, | ||
org.eclipse.jdt.annotation;resolution:=optional, | ||
org.eclipse.smarthome.core.auth, | ||
org.eclipse.smarthome.core.binding, | ||
org.eclipse.smarthome.core.binding.dto, | ||
org.eclipse.smarthome.core.cache, | ||
org.eclipse.smarthome.core.common, | ||
org.eclipse.smarthome.core.common.osgi, | ||
org.eclipse.smarthome.core.common.registry, | ||
org.eclipse.smarthome.core.events, | ||
org.eclipse.smarthome.core.extension, | ||
org.eclipse.smarthome.core.i18n, | ||
org.eclipse.smarthome.core.items, | ||
org.eclipse.smarthome.core.items.dto, | ||
org.eclipse.smarthome.core.items.events, | ||
org.eclipse.smarthome.core.library, | ||
org.eclipse.smarthome.core.library.dimension, | ||
org.eclipse.smarthome.core.library.items, | ||
org.eclipse.smarthome.core.library.types, | ||
org.eclipse.smarthome.core.library.unit, | ||
org.eclipse.smarthome.core.net, | ||
org.eclipse.smarthome.core.scheduler, | ||
org.eclipse.smarthome.core.service, | ||
org.eclipse.smarthome.core.storage, | ||
org.eclipse.smarthome.core.types, | ||
org.eclipse.smarthome.core.types.util, | ||
org.osgi.framework, | ||
org.osgi.service.component, | ||
org.osgi.service.event, | ||
org.osgi.service.packageadmin, | ||
org.osgi.util.tracker, | ||
org.slf4j, | ||
tec.uom.lib.common, | ||
tec.uom.se, | ||
tec.uom.se.format, | ||
tec.uom.se.function, | ||
tec.uom.se.quantity, | ||
tec.uom.se.unit | ||
Private-Package: org.eclipse.smarthome.core.internal,org.eclipse.smartho | ||
me.core.internal.events,org.eclipse.smarthome.core.internal.items,org.e | ||
clipse.smarthome.core.internal.logging,org.eclipse.smarthome.core.internal.items.group | ||
Service-Component: OSGI-INF/*.xml | ||
Manifest-Version: 1.0 | ||
Bundle-License: https://www.eclipse.org/legal/epl-2.0/ | ||
Bundle-ManifestVersion: 2 | ||
Bundle-Name: Eclipse SmartHome Core | ||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 | ||
Bundle-SymbolicName: org.eclipse.smarthome.core | ||
Bundle-Vendor: Eclipse.org/SmartHome | ||
Bundle-Version: 0.10.0.qualifier | ||
Export-Package: | ||
org.eclipse.smarthome.core.auth, | ||
org.eclipse.smarthome.core.auth.client.oauth2, | ||
org.eclipse.smarthome.core.binding, | ||
org.eclipse.smarthome.core.binding.dto, | ||
org.eclipse.smarthome.core.cache, | ||
org.eclipse.smarthome.core.common, | ||
org.eclipse.smarthome.core.common.osgi, | ||
org.eclipse.smarthome.core.common.registry, | ||
org.eclipse.smarthome.core.events;uses:="org.eclipse.smarthome.core.items,org.osgi.service.event,org.eclipse.smarthome.core.types", | ||
org.eclipse.smarthome.core.extension, | ||
org.eclipse.smarthome.core.i18n, | ||
org.eclipse.smarthome.core.items;uses:="org.eclipse.smarthome.core.types,org.eclipse.smarthome.core.events", | ||
org.eclipse.smarthome.core.items.dto, | ||
org.eclipse.smarthome.core.items.events, | ||
org.eclipse.smarthome.core.library, | ||
org.eclipse.smarthome.core.library.dimension, | ||
org.eclipse.smarthome.core.library.items, | ||
org.eclipse.smarthome.core.library.types, | ||
org.eclipse.smarthome.core.library.unit, | ||
org.eclipse.smarthome.core.net, | ||
org.eclipse.smarthome.core.scheduler, | ||
org.eclipse.smarthome.core.service, | ||
org.eclipse.smarthome.core.storage, | ||
org.eclipse.smarthome.core.types, | ||
org.eclipse.smarthome.core.types.util, | ||
org.eclipse.smarthome.core.util | ||
Ignore-Package: org.eclipse.smarthome.core.internal.items,org.eclipse.sm | ||
arthome.core.internal,org.eclipse.smarthome.core.internal.events,org.ec | ||
lipse.smarthome.core.internal.logging | ||
Import-Package: | ||
com.google.common.collect, | ||
com.google.gson, | ||
javax.measure, | ||
javax.measure.quantity, | ||
javax.measure.spi, | ||
org.apache.commons.io, | ||
org.apache.commons.lang, | ||
org.eclipse.jdt.annotation;resolution:=optional, | ||
org.eclipse.smarthome.core.auth, | ||
org.eclipse.smarthome.core.binding, | ||
org.eclipse.smarthome.core.binding.dto, | ||
org.eclipse.smarthome.core.cache, | ||
org.eclipse.smarthome.core.common, | ||
org.eclipse.smarthome.core.common.osgi, | ||
org.eclipse.smarthome.core.common.registry, | ||
org.eclipse.smarthome.core.events, | ||
org.eclipse.smarthome.core.extension, | ||
org.eclipse.smarthome.core.i18n, | ||
org.eclipse.smarthome.core.items, | ||
org.eclipse.smarthome.core.items.dto, | ||
org.eclipse.smarthome.core.items.events, | ||
org.eclipse.smarthome.core.library, | ||
org.eclipse.smarthome.core.library.dimension, | ||
org.eclipse.smarthome.core.library.items, | ||
org.eclipse.smarthome.core.library.types, | ||
org.eclipse.smarthome.core.library.unit, | ||
org.eclipse.smarthome.core.net, | ||
org.eclipse.smarthome.core.scheduler, | ||
org.eclipse.smarthome.core.service, | ||
org.eclipse.smarthome.core.storage, | ||
org.eclipse.smarthome.core.types, | ||
org.eclipse.smarthome.core.types.util, | ||
org.eclipse.smarthome.io.json, | ||
org.osgi.framework, | ||
org.osgi.service.component, | ||
org.osgi.service.event, | ||
org.osgi.service.packageadmin, | ||
org.osgi.util.tracker, | ||
org.slf4j, | ||
tec.uom.lib.common, | ||
tec.uom.se, | ||
tec.uom.se.format, | ||
tec.uom.se.function, | ||
tec.uom.se.quantity, | ||
tec.uom.se.unit | ||
Private-Package: org.eclipse.smarthome.core.internal,org.eclipse.smartho | ||
me.core.internal.events,org.eclipse.smarthome.core.internal.items,org.e | ||
clipse.smarthome.core.internal.logging,org.eclipse.smarthome.core.internal.items.group | ||
Service-Component: OSGI-INF/*.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<classpath> | ||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/> | ||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/> | ||
<classpathentry kind="src" path="src/main/java"/> | ||
<classpathentry kind="output" path="target/classes"/> | ||
</classpath> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<projectDescription> | ||
<name>org.eclipse.smarthome.io.json.gson</name> | ||
<comment></comment> | ||
<projects> | ||
</projects> | ||
<buildSpec> | ||
<buildCommand> | ||
<name>org.eclipse.jdt.core.javabuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.pde.ManifestBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.pde.SchemaBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.pde.ds.core.builder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
</buildSpec> | ||
<natures> | ||
<nature>org.eclipse.pde.PluginNature</nature> | ||
<nature>org.eclipse.jdt.core.javanature</nature> | ||
</natures> | ||
</projectDescription> |
14 changes: 14 additions & 0 deletions
14
bundles/io/org.eclipse.smarthome.io.json.gson/META-INF/MANIFEST.MF
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
Manifest-Version: 1.0 | ||
Bundle-ManifestVersion: 2 | ||
Bundle-Name: Eclipse SmartHome JSON Data Binding Gson Implementation | ||
Bundle-SymbolicName: org.eclipse.smarthome.io.json.gson | ||
Bundle-Version: 0.10.0.qualifier | ||
Automatic-Module-Name: org.eclipse.smarthome.io.json.gson | ||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 | ||
Import-Package: com.google.gson, | ||
org.eclipse.jdt.annotation;resolution:=optional, | ||
org.eclipse.smarthome.io.json, | ||
org.slf4j | ||
Service-Component: OSGI-INF/*.xml | ||
Bundle-ActivationPolicy: lazy | ||
Export-Package: org.eclipse.smarthome.io.json.gson |
1 change: 1 addition & 0 deletions
1
bundles/io/org.eclipse.smarthome.io.json.gson/OSGI-INF/.gitignore
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/*.xml |
5 changes: 5 additions & 0 deletions
5
bundles/io/org.eclipse.smarthome.io.json.gson/build.properties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
source.. = src/main/java/ | ||
output.. = target/classes/ | ||
bin.includes = META-INF/,\ | ||
.,\ | ||
OSGI-INF/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> | ||
|
||
<modelVersion>4.0.0</modelVersion> | ||
|
||
<parent> | ||
<groupId>org.eclipse.smarthome.bundles</groupId> | ||
<artifactId>io</artifactId> | ||
<version>0.10.0-SNAPSHOT</version> | ||
</parent> | ||
<groupId>org.eclipse.smarthome.io</groupId> | ||
<artifactId>org.eclipse.smarthome.io.json.gson</artifactId> | ||
|
||
<packaging>eclipse-plugin</packaging> | ||
|
||
<name>Eclipse SmartHome JSON Data Binding Gson Implementation</name> | ||
|
||
<properties> | ||
<bundle.symbolicName>org.eclipse.smarthome.io.json.gson</bundle.symbolicName> | ||
<bundle.namespace>org.eclipse.smarthome.io.json.gson</bundle.namespace> | ||
</properties> | ||
<description>Provides JSON data binding support for Eclipse SmartHome based on Gson.</description> | ||
</project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
Oops, something went wrong.