README.md 3.09 KB
Newer Older
1
2
3
4
jCoAP is a java implementation of the Contrained Application Protocol (RFC 7252).
It supports:
* RFC 7641 CoAP Observe
* RFC 7390 CoAP Group Communication
Björn Butzin's avatar
Björn Butzin committed
5
* RFC 7959 CoAP Blockwise Transfer
6
7
* RFC 6690 CoRE Link Format (.well-known/core)

8
9
10
11
# Latest Releases

The latest releases can be downloadede here: [ws4d-jcoap/release](https://gitlab.amd.e-technik.uni-rostock.de/ws4d/jcoap/tree/master/ws4d-jcoap/release)

12
13
14
15
16
17
18
19
20
# Build using Maven

You need to have a working maven installation to build jCoAP.
Then simply run the following from the project's root directory:

```sh
$ mvn clean install
```

21
Executable JARs including all dependencies can be found in the `target\` folder afterwards.
22

Björn Butzin's avatar
Björn Butzin committed
23
# Usage in Maven Projects
24

Björn Butzin's avatar
Björn Butzin committed
25
26
27
jCoAP and its projects are currently not uploaded to any Maven repository!
Thus you need to build jcoap projects once on your local machine (see "Build using Maven") before you can use them.
During build, the binary will be put to the local maven repository on your machine.
28

Björn Butzin's avatar
Björn Butzin committed
29
To use jCoAP core as a library in your projects, add the following dependency to your `pom.xml`:
30
```xml
Björn Butzin's avatar
Björn Butzin committed
31
32
<dependency>
	<groupId>org.ws4d.jcoap</groupId>
33
	<artifactId>jcoap-core</artifactId>
Björn Butzin's avatar
Björn Butzin committed
34
	<version>1.1.5</version>
Björn Butzin's avatar
Björn Butzin committed
35
</dependency>
36
37
```

Björn Butzin's avatar
Björn Butzin committed
38
39
40
41
To use jCoAP proxy as a library in your projects, add the following dependency to your `pom.xml`:
```xml
<dependency>
	<groupId>org.ws4d.jcoap</groupId>
42
	<artifactId>jcoap-proxy</artifactId>
Björn Butzin's avatar
Björn Butzin committed
43
	<version>0.0.2</version>
Björn Butzin's avatar
Björn Butzin committed
44
45
</dependency>
```
46

47
48
49
# Eclipse

The project can be easily imported into a recent version of the Eclipse IDE.
Björn Butzin's avatar
Björn Butzin committed
50
Make sure to have the following before importing:
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66

* [Eclipse EGit](http://www.eclipse.org/egit/) (should be the case with every recent Eclipse version)
* [m2e - Maven Integration for Eclipse](http://www.eclipse.org/m2e/) (should be the case with every recent Eclipse version)
* UTF-8 workspace text file encoding (Preferences &raquo; General &raquo; Workspace)

Then choose *[Import... &raquo; Maven &raquo; Existing Maven Projects]* to import `jCoAP projects` into Eclipse.

To run the build process from Eclipse select a project then right click *[Run As &raquo; Maven install]*

# IntelliJ

The project can also be imported to IntelliJ as follows:

In IntelliJ, choose *[File.. &raquo; Open]* then select the location of the cloned repository in your filesystem.
IntelliJ will then automatically import all projects and resolve required Maven dependencies.

Björn Butzin's avatar
Björn Butzin committed
67
68
69
# Tutorial and Examples

The [ws4d-jcoap-handsOn](https://gitlab.amd.e-technik.uni-rostock.de/ws4d/jcoap/tree/master/ws4d-jcoap-handsOn) project provides a guided tutorial to the most common functions of jCoAP.
70

Björn Butzin's avatar
Björn Butzin committed
71
72
Example-code can be found in the [ws4d-jcoap-examples](https://gitlab.amd.e-technik.uni-rostock.de/ws4d/jcoap/tree/master/ws4d-jcoap-examples) project.

73
# License
Björn Butzin's avatar
links    
Björn Butzin committed
74
jCoAP is licensed under [Apache License, Version 2.0](./license.txt) see `license.txt`
75
76

# Third Party Software
77
jCoAP uses the folowing third party components
Björn Butzin's avatar
links    
Björn Butzin committed
78
79
* [log4j](https://logging.apache.org/log4j/) - [Apache License - v 2.0](http://www.apache.org/licenses/LICENSE-2.0.html)
* [jUnit](http://junit.org) - [Eclipse Public License - v 1.0](https://www.eclipse.org/legal/epl-v10.html)