rdflib 2.2.9 → 2.2.10-4fa7e876

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -14,7 +14,7 @@ kb?: IndexedFormula, base?: unknown,
14
14
  * The mime type.
15
15
  * Defaults to Turtle.
16
16
  */
17
- contentType?: string | ContentType, callback?: (err: Error | undefined | null, result?: string | null) => any, options?: {
17
+ contentType?: string | ContentType, callback?: (err: Error | undefined | null, result?: string) => any, options?: {
18
18
  /**
19
19
  * A string of letters, each of which set an options
20
20
  * e.g. `deinprstux`
package/lib/serialize.js CHANGED
@@ -36,7 +36,7 @@ contentType, callback, options) {
36
36
  var opts = options || {};
37
37
  contentType = contentType || _types.TurtleContentType; // text/n3 if complex?
38
38
 
39
- var documentString = null;
39
+ var documentString = undefined;
40
40
 
41
41
  try {
42
42
  var sz = (0, _serializer.default)(kb);
@@ -0,0 +1,54 @@
1
+ export default function createSerializer(store: any): Serializer;
2
+ export class Serializer {
3
+ constructor(store: any);
4
+ flags: string;
5
+ base: any;
6
+ prefixes: string[];
7
+ namespaces: any[];
8
+ namespacesUsed: any[];
9
+ keywords: string[];
10
+ prefixchars: string;
11
+ incoming: {} | null;
12
+ formulas: any[];
13
+ store: any;
14
+ rdfFactory: any;
15
+ xsd: {
16
+ boolean: NamedNode;
17
+ dateTime: NamedNode;
18
+ decimal: NamedNode;
19
+ double: NamedNode;
20
+ integer: NamedNode;
21
+ langString: NamedNode;
22
+ string: NamedNode;
23
+ };
24
+ setBase(base: any): Serializer;
25
+ setFlags(flags: any): Serializer;
26
+ toStr(x: any): any;
27
+ fromStr(s: any): any;
28
+ suggestPrefix(prefix: any, uri: any): void;
29
+ suggestNamespaces(namespaces: any): Serializer;
30
+ checkIntegrity(): void;
31
+ makeUpPrefix(uri: any): any;
32
+ rootSubjects(sts: any): {
33
+ roots: any[];
34
+ subjects: {};
35
+ rootsHash: {};
36
+ incoming: {};
37
+ };
38
+ toN3(f: any): string;
39
+ _notQNameChars: string;
40
+ _notNameChars: string;
41
+ explicitURI(uri: any): string;
42
+ statementsToNTriples(sts: any): string;
43
+ statementsToN3(sts: any): string;
44
+ defaultNamespace: string | undefined;
45
+ atomicTermToN3(expr: any, stats: any): any;
46
+ validPrefix: RegExp;
47
+ forbidden1: RegExp;
48
+ forbidden3: RegExp;
49
+ stringToN3(str: any, flags: any): string;
50
+ symbolToN3(x: any): any;
51
+ writeStore(write: any): void;
52
+ statementsToXML(sts: any): string;
53
+ }
54
+ import NamedNode from "./named-node";