File tree Expand file tree Collapse file tree 7 files changed +62
-12
lines changed Expand file tree Collapse file tree 7 files changed +62
-12
lines changed Original file line number Diff line number Diff line change 19
19
20
20
import { int , isInt } from './v1/integer' ;
21
21
import Driver from './v1/driver' ;
22
+ import VERSION from './version' ;
23
+ import * as v1 from './v1/index.js' ;
22
24
23
- let USER_AGENT = "neo4j-javascript/0.0" ;
25
+ let USER_AGENT = "neo4j-javascript/" + VERSION ;
26
+
27
+ console . log ( v1 ) ;
24
28
25
29
export default {
26
- v1 : {
27
- driver : ( url ) => new Driver ( url , USER_AGENT ) ,
28
- int : int ,
29
- isInt : isInt
30
- }
30
+ v1 : v1
31
31
}
Original file line number Diff line number Diff line change
1
+ /**
2
+ * Copyright (c) 2002-2015 "Neo Technology,"
3
+ * Network Engine for Objects in Lund AB [http://neotechnology.com]
4
+ *
5
+ * This file is part of Neo4j.
6
+ *
7
+ * Licensed under the Apache License, Version 2.0 (the "License");
8
+ * you may not use this file except in compliance with the License.
9
+ * You may obtain a copy of the License at
10
+ *
11
+ * http://www.apache.org/licenses/LICENSE-2.0
12
+ *
13
+ * Unless required by applicable law or agreed to in writing, software
14
+ * distributed under the License is distributed on an "AS IS" BASIS,
15
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16
+ * See the License for the specific language governing permissions and
17
+ * limitations under the License.
18
+ */
19
+
20
+ import { int , isInt } from './integer' ;
21
+ import Driver from './driver' ;
22
+ import { VERSION } from '../version' ;
23
+
24
+ let USER_AGENT = "neo4j-javascript/" + VERSION ;
25
+
26
+ export default {
27
+ driver : ( url ) => new Driver ( url , USER_AGENT ) ,
28
+ int : int ,
29
+ isInt : isInt
30
+ }
Original file line number Diff line number Diff line change 17
17
* limitations under the License.
18
18
*/
19
19
20
- import neo4j from '../index ' ;
20
+ import { int , isInt } from './integer ' ;
21
21
22
22
/**
23
23
* A ResultSummary instance contains structured metadata for a {Result}.
@@ -126,7 +126,7 @@ class StatementStatistics {
126
126
constraintsRemoved : 0
127
127
}
128
128
Object . keys ( statistics ) . forEach ( ( index ) => {
129
- let val = neo4j . v1 . isInt ( statistics [ index ] ) ? statistics [ index ] . toInt ( ) : statistics [ index ] ;
129
+ let val = isInt ( statistics [ index ] ) ? statistics [ index ] . toInt ( ) : statistics [ index ] ;
130
130
//To camelCase
131
131
this . _stats [ index . replace ( / ( \- \w ) / g, ( m ) => m [ 1 ] . toUpperCase ( ) ) ] = val ;
132
132
} ) ;
Original file line number Diff line number Diff line change
1
+ /**
2
+ * Copyright (c) 2002-2015 "Neo Technology,"
3
+ * Network Engine for Objects in Lund AB [http://neotechnology.com]
4
+ *
5
+ * This file is part of Neo4j.
6
+ *
7
+ * Licensed under the Apache License, Version 2.0 (the "License");
8
+ * you may not use this file except in compliance with the License.
9
+ * You may obtain a copy of the License at
10
+ *
11
+ * http://www.apache.org/licenses/LICENSE-2.0
12
+ *
13
+ * Unless required by applicable law or agreed to in writing, software
14
+ * distributed under the License is distributed on an "AS IS" BASIS,
15
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16
+ * See the License for the specific language governing permissions and
17
+ * limitations under the License.
18
+ */
19
+
20
+ export default { VERSION : "0.0.0-dev" } ;
Original file line number Diff line number Diff line change 17
17
* limitations under the License.
18
18
*/
19
19
20
- var neo4j = require ( "../lib/index" ) . v1 ;
20
+ var neo4j = require ( "../../ lib/v1" ) ;
21
21
22
22
describe ( 'driver' , function ( ) {
23
23
it ( 'should expose sessions' , function ( ) {
Original file line number Diff line number Diff line change 17
17
* limitations under the License.
18
18
*/
19
19
20
- var neo4j = require ( "../lib/index" ) . v1 ;
21
- var StatementType = require ( "../lib/v1/result-summary" ) . statementType ;
20
+ var neo4j = require ( "../../ lib/v1" ) ;
21
+ var StatementType = require ( "../../ lib/v1/result-summary" ) . statementType ;
22
22
23
23
describe ( 'session' , function ( ) {
24
24
it ( 'should expose basic run/subscribe ' , function ( done ) {
Original file line number Diff line number Diff line change 17
17
* limitations under the License.
18
18
*/
19
19
20
- var neo4j = require ( "../lib/index" ) . v1 ;
20
+ var neo4j = require ( "../../ lib/v1" ) ;
21
21
22
22
describe ( 'floating point values' , function ( ) {
23
23
it ( 'should support float 1.0 ' , testVal ( 1 ) ) ;
You can’t perform that action at this time.
0 commit comments