Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 127 lines (92 sloc) 4.644 kb
982009d Michel Krämer Added readme
authored
1 ================
2 BSON for Jackson
3 ================
4
5 This library adds support for `BSON <http://bsonspec.org>`_ to the
3d2915e Michel Krämer Updated link to Jackson
authored
6 `Jackson JSON processor <https://github.com/FasterXML/jackson>`_.
982009d Michel Krämer Added readme
authored
7
8 BSON is a binary representation of `JSON <http://json.org/>`_. It has
9 gained prominence by its usage as the main exchange and persistence
10 format of the document-oriented database management system `MongoDB
11 <http://www.mongodb.com>`_.
12
3e2ceed Michel Krämer Updated README file. Added license and Maven repo.
authored
13 Usage
14 -----
15
16 The bson4jackson library integrates completely into Jackson. Please have
17 a look at the `Jackson wiki <http://wiki.fasterxml.com/JacksonDocumentation>`_
18 for a complete description. For more information you may also have a
ec1dd97 Michel Krämer Updated readme for 2.0
authored
19 look at the `bson4jackson tutorial <http://www.michel-kraemer.com/binary-json-with-bson4jackson>`_.
3e2ceed Michel Krämer Updated README file. Added license and Maven repo.
authored
20
21 The BSON specification defines some additional types not available in
22 the original JSON specification. These types are mapped to simple
23 wrapper objects.
24
25 Download
26 --------
27
28 bson4jackson binaries are available from the
6dee71e Michel Krämer Link to releases
authored
29 `GitHub Releases page <https://github.com/michel-kraemer/bson4jackson/releases>`_.
3e2ceed Michel Krämer Updated README file. Added license and Maven repo.
authored
30
31 You may also use `Maven <http://maven.apache.org/>`_ to download bson4jackson::
32
33 <dependencies>
34 <dependency>
35 <groupId>de.undercouch</groupId>
36 <artifactId>bson4jackson</artifactId>
5e395be Michel Krämer Bumped up version number
authored
37 <version>2.4.0</version>
3e2ceed Michel Krämer Updated README file. Added license and Maven repo.
authored
38 </dependency>
39 </dependencies>
40
691df0b Michel Krämer Migrated to gradle
authored
41 If you're using `Gradle <http://www.gradle.org/>`_, you may add the
42 following snippet to your ``build.gradle``::
43
44 dependencies {
5e395be Michel Krämer Bumped up version number
authored
45 compile 'de.undercouch:bson4jackson:2.4.0'
691df0b Michel Krämer Migrated to gradle
authored
46 }
47
48 For `sbt <http://code.google.com/p/simple-build-tool/>`_,
49 add the following line to your project::
3e2ceed Michel Krämer Updated README file. Added license and Maven repo.
authored
50
5e395be Michel Krämer Bumped up version number
authored
51 val bson4jackson = "de.undercouch" % "bson4jackson" % "2.4.0"
3e2ceed Michel Krämer Updated README file. Added license and Maven repo.
authored
52
2fe8e0c Michel Krämer Added download instructions for buildr
authored
53 For `buildr <http://buildr.apache.org/>`_ use the following snippet::
54
5e395be Michel Krämer Bumped up version number
authored
55 compile.with 'de.undercouch:bson4jackson:jar:2.4.0'
2fe8e0c Michel Krämer Added download instructions for buildr
authored
56
8476f5d Michel Krämer Added section about compatibility
authored
57 Compatibility
58 -------------
59
14959fc Michel Krämer Added compatibility matrix
authored
60 bson4jackson 2.x is compatible to Jackson 2.x and higher. Due to some
61 compatibility issues both libraries' major and minor version numbers
62 have to match. That means you have to use at least bson4jackson 2.1
63 if you use Jackson 2.1, bson4jackson 2.2 if you use Jackson 2.2, etc.
64 I will try to keep bson4jackson up to date. If there is a compatibility
65 issue I will update bson4jackon, usually within a couple of days after
66 the new Jackson version has been released.
67
68 Here's the compatibility matrix for the current library versions:
69
5e395be Michel Krämer Bumped up version number
authored
70 ==================== =============== =============== =============== ===============
71 Library Jackson 2.4.x Jackson 2.3.x Jackson 2.2.x Jackson 2.1.x
72 -------------------- --------------- --------------- --------------- ---------------
73 bson4jackson 2.4.x Yes Yes Yes Yes
74 -------------------- --------------- --------------- --------------- ---------------
75 bson4jackson 2.3.x No Yes Yes Yes
76 -------------------- --------------- --------------- --------------- ---------------
77 bson4jackson 2.2.x No No Yes Yes
78 -------------------- --------------- --------------- --------------- ---------------
79 bson4jackson 2.1.x No No No Yes
80 ==================== =============== =============== =============== ===============
ec1dd97 Michel Krämer Updated readme for 2.0
authored
81
82 If you're looking for a version compatible to Jackson 1.x, please use
83 bson4jackson 1.3.0. It's the last version for the 1.x branch.
84 bson4jackson 1.3.0 is compatible to Jackson 1.7 up to 1.9.
8476f5d Michel Krämer Added section about compatibility
authored
85
3e2ceed Michel Krämer Updated README file. Added license and Maven repo.
authored
86 License
87 -------
88
89 bson4jackson is licensed under the
90 `Apache License, Version 2.0 <http://www.apache.org/licenses/LICENSE-2.0>`_.
91
92 Unless required by applicable law or agreed to in writing, software
93 distributed under the License is distributed on an "AS IS" BASIS,
94 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
95 See the License for the specific language governing permissions and
96 limitations under the License.
97
982009d Michel Krämer Added readme
authored
98 Compiling
99 ---------
100
5759e36 Michel Krämer Let travis-ci do continuous integration
authored
101 .. image:: https://secure.travis-ci.org/michel-kraemer/bson4jackson.png?branch=master
102 :alt: Build Status
103 :target: http://travis-ci.org/michel-kraemer/bson4jackson
104
982009d Michel Krämer Added readme
authored
105 Execute the following command to compile the library and to run the
106 unit tests::
107
691df0b Michel Krämer Migrated to gradle
authored
108 ./gradlew test
982009d Michel Krämer Added readme
authored
109
691df0b Michel Krämer Migrated to gradle
authored
110 The script automatically downloads the correct Gradle version, so you
111 won't have to do anything else. If everything runs successfully, you
112 may create a .jar library::
982009d Michel Krämer Added readme
authored
113
691df0b Michel Krämer Migrated to gradle
authored
114 ./gradlew jar
982009d Michel Krämer Added readme
authored
115
691df0b Michel Krämer Migrated to gradle
authored
116 The library will be located under the ``build/libs`` directory.
982009d Michel Krämer Added readme
authored
117
118 Eclipse
119 .......
120
691df0b Michel Krämer Migrated to gradle
authored
121 Gradle includes a task that creates all files required to develop
b9c82b7 Michel Krämer Updated build instructions
authored
122 bson4jackson in Eclipse. Run the following command::
982009d Michel Krämer Added readme
authored
123
691df0b Michel Krämer Migrated to gradle
authored
124 ./gradlew eclipse
b9c82b7 Michel Krämer Updated build instructions
authored
125
691df0b Michel Krämer Migrated to gradle
authored
126 Then import the project into your workspace.
Something went wrong with that request. Please try again.