@dcmjs-org/parser 1.0.0-beta.1 → 1.0.0-beta.3

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.
package/dist/index.mjs CHANGED
@@ -1,4 +1,5 @@
1
- import { lookupTagHex, isMultiVM, addAccessors, log, dicomJson, lookupPrivateTag, Tag, DicomMetaDictionary, ValueRepresentation, resolveCharsetDecoder, ReadBufferStream, UNDEFINED_LENGTH, singleVRs, VM_DELIMITER, DEFLATED_EXPLICIT_LITTLE_ENDIAN, EXPLICIT_LITTLE_ENDIAN, IMPLICIT_LITTLE_ENDIAN, VALID_VRS, normalizeSyntax, EXPLICIT_BIG_ENDIAN } from '@dcmjs-org/core';
1
+ import { lookupTagHex, isMultiVM, addAccessors, log, dicomJson, lookupPrivateTag, base64ToArrayBuffer, Tag, DicomMetaDictionary, ValueRepresentation, resolveCharsetDecoder, ReadBufferStream, UNDEFINED_LENGTH, singleVRs, VM_DELIMITER, DEFLATED_EXPLICIT_LITTLE_ENDIAN, EXPLICIT_LITTLE_ENDIAN, IMPLICIT_LITTLE_ENDIAN, VALID_VRS, normalizeSyntax, EXPLICIT_BIG_ENDIAN } from '@dcmjs-org/core';
2
+ export { base64ToArrayBuffer } from '@dcmjs-org/core';
2
3
  import pako from 'pako';
3
4
 
4
5
  /**
@@ -800,23 +801,6 @@ function isMetaTag(tag) {
800
801
  return tag.slice(0, 4) === "0002";
801
802
  }
802
803
 
803
- /** Decode a base64 string into an ArrayBuffer (Node and browser). */
804
- function base64ToArrayBuffer(b64) {
805
- if (typeof Buffer !== "undefined") {
806
- const buf = Buffer.from(b64, "base64");
807
- return buf.buffer.slice(
808
- buf.byteOffset,
809
- buf.byteOffset + buf.byteLength
810
- );
811
- }
812
- const binary = atob(b64);
813
- const bytes = new Uint8Array(binary.length);
814
- for (let i = 0; i < binary.length; i++) {
815
- bytes[i] = binary.charCodeAt(i);
816
- }
817
- return bytes.buffer;
818
- }
819
-
820
804
  /**
821
805
  * fromDataSet — the reference event-stream generator for slice A.
822
806
  *
@@ -3204,5 +3188,5 @@ async function fromPart10(buffer, listener, options = {}) {
3204
3188
  await fromPart10Stream(bytes, listener, options);
3205
3189
  }
3206
3190
 
3207
- export { CONTRACT_VERSION, CollectorListener, EVENT_STREAM_VOCABULARY, EventStreamListener, NaturalizedListener, base64ToArrayBuffer, createEventAsyncIterable, emitDecodedLeaf, emitEntry, emitValues, fromDataSet, fromDicomWebJson, fromPart10, fromPart10Stream, mergeFragmentsPerBotWindow };
3191
+ export { CONTRACT_VERSION, CollectorListener, EVENT_STREAM_VOCABULARY, EventStreamListener, NaturalizedListener, createEventAsyncIterable, emitDecodedLeaf, emitEntry, emitValues, fromDataSet, fromDicomWebJson, fromPart10, fromPart10Stream, mergeFragmentsPerBotWindow };
3208
3192
  //# sourceMappingURL=index.mjs.map