Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@xyo-network/hashing

Package Overview
Dependencies
Maintainers
4
Versions
61
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@xyo-network/hashing - npm Package Compare versions

Comparing version 0.5.0 to 0.6.0

4

dist/index.d.ts
/// <reference types="node" />
import { IXyoHashProvider, IXyoHash } from './@types';
import { IXyoDeserializer } from '@xyo-network/serialization';
import { IXyoDeserializer, IXyoSerializationService } from '@xyo-network/serialization';
export { IXyoHash, IXyoHashProvider } from './@types';

@@ -21,5 +21,5 @@ export { XyoHash } from './xyo-hash';

schemaObjectId: number;
deserialize(data: Buffer): IXyoHash;
deserialize(data: Buffer, serializationService: IXyoSerializationService): IXyoHash;
}
export declare const sha256HashDeserializer: XyoSha256HashDeserializer;
//# sourceMappingURL=index.d.ts.map

@@ -8,3 +8,3 @@ "use strict";

* @Last modified by: ryanxyo
* @Last modified time: Tuesday, 11th December 2018 9:40:03 am
* @Last modified time: Wednesday, 12th December 2018 11:04:16 am
* @License: All Rights Reserved

@@ -55,4 +55,4 @@ * @Copyright: Copyright XY | The Findables Company

}
deserialize(data) {
const parseResult = serialization_1.parse(data);
deserialize(data, serializationService) {
const parseResult = serialization_1.parse(data, serializationService.schema);
const hashProvider = getHashingProvider('sha256');

@@ -59,0 +59,0 @@ return new xyo_hash_1.XyoHash(parseResult.data, hashProvider, this.schemaObjectId);

@@ -8,3 +8,3 @@ "use strict";

* @Last modified by: ryanxyo
* @Last modified time: Monday, 10th December 2018 10:00:26 am
* @Last modified time: Wednesday, 12th December 2018 11:05:01 am
* @License: All Rights Reserved

@@ -23,5 +23,6 @@ * @Copyright: Copyright XY | The Findables Company

const xyo_base_hash_1 = require("./xyo-base-hash");
const serialization_schema_1 = require("@xyo-network/serialization-schema");
class XyoHash extends xyo_base_hash_1.XyoBaseHash {
constructor(hash, hashProvider, schemaObjectId) {
super();
super(serialization_schema_1.schema);
this.hash = hash;

@@ -28,0 +29,0 @@ this.hashProvider = hashProvider;

/// <reference types="node" />
import { XyoBaseHash } from "./xyo-base-hash";
import { IXyoSerializationService } from "@xyo-network/serialization";
export declare class XyoStubHash extends XyoBaseHash {
private readonly hash;
static schemaObjectId: number;
static deserialize(data: Buffer): XyoStubHash;
static deserialize(data: Buffer, serializationService: IXyoSerializationService): XyoStubHash;
schemaObjectId: number;

@@ -8,0 +9,0 @@ constructor(hash: Buffer);

@@ -8,3 +8,3 @@ "use strict";

* @Last modified by: ryanxyo
* @Last modified time: Tuesday, 11th December 2018 9:23:43 am
* @Last modified time: Wednesday, 12th December 2018 11:05:40 am
* @License: All Rights Reserved

@@ -27,8 +27,8 @@ * @Copyright: Copyright XY | The Findables Company

constructor(hash) {
super();
super(serialization_schema_1.schema);
this.hash = hash;
this.schemaObjectId = serialization_schema_1.schema.stubHash.id;
}
static deserialize(data) {
const parseResult = serialization_1.parse(data);
static deserialize(data, serializationService) {
const parseResult = serialization_1.parse(data, serializationService.schema);
return new XyoStubHash(parseResult.data);

@@ -35,0 +35,0 @@ }

{
"name": "@xyo-network/hashing",
"version": "0.5.0",
"version": "0.6.0",
"description": "Hashing Types and Services for the Xyo Network",

@@ -10,6 +10,6 @@ "main": "dist/index.js",

"dependencies": {
"@xyo-network/base": "^0.5.0",
"@xyo-network/errors": "^0.5.0",
"@xyo-network/serialization": "^0.5.0",
"@xyo-network/serialization-schema": "^0.5.0"
"@xyo-network/base": "^0.6.0",
"@xyo-network/errors": "^0.6.0",
"@xyo-network/serialization": "^0.6.0",
"@xyo-network/serialization-schema": "^0.6.0"
},

@@ -25,3 +25,3 @@ "devDependencies": {

},
"gitHead": "599cd70f6ec81a60314d6f855a8735f5fdb08c99"
"gitHead": "cbb5c5c20b4f081ebbd619dbdbd2ddace174db34"
}

@@ -7,3 +7,3 @@ /*

* @Last modified by: ryanxyo
* @Last modified time: Tuesday, 11th December 2018 9:40:03 am
* @Last modified time: Wednesday, 12th December 2018 11:04:16 am
* @License: All Rights Reserved

@@ -17,3 +17,3 @@ * @Copyright: Copyright XY | The Findables Company

import { schema } from '@xyo-network/serialization-schema'
import { IXyoDeserializer, parse } from '@xyo-network/serialization'
import { IXyoDeserializer, parse, IXyoSerializationService } from '@xyo-network/serialization'
import { XyoHash } from './xyo-hash'

@@ -68,4 +68,4 @@

public deserialize(data: Buffer): IXyoHash {
const parseResult = parse(data)
public deserialize(data: Buffer, serializationService: IXyoSerializationService): IXyoHash {
const parseResult = parse(data, serializationService.schema)
const hashProvider = getHashingProvider('sha256')

@@ -72,0 +72,0 @@ return new XyoHash(

@@ -7,3 +7,3 @@ /*

* @Last modified by: ryanxyo
* @Last modified time: Monday, 10th December 2018 10:00:26 am
* @Last modified time: Wednesday, 12th December 2018 11:05:01 am
* @License: All Rights Reserved

@@ -15,2 +15,3 @@ * @Copyright: Copyright XY | The Findables Company

import { IXyoHash, IXyoHashProvider } from "./@types"
import { schema } from '@xyo-network/serialization-schema'

@@ -24,3 +25,3 @@ export class XyoHash extends XyoBaseHash implements IXyoHash {

) {
super()
super(schema)
}

@@ -27,0 +28,0 @@

@@ -7,3 +7,3 @@ /*

* @Last modified by: ryanxyo
* @Last modified time: Tuesday, 11th December 2018 9:23:43 am
* @Last modified time: Wednesday, 12th December 2018 11:05:40 am
* @License: All Rights Reserved

@@ -15,3 +15,3 @@ * @Copyright: Copyright XY | The Findables Company

import { schema } from "@xyo-network/serialization-schema"
import { parse } from "@xyo-network/serialization"
import { parse, IXyoSerializationService } from "@xyo-network/serialization"

@@ -22,4 +22,4 @@ export class XyoStubHash extends XyoBaseHash {

public static deserialize(data: Buffer) {
const parseResult = parse(data)
public static deserialize(data: Buffer, serializationService: IXyoSerializationService) {
const parseResult = parse(data, serializationService.schema)
return new XyoStubHash(parseResult.data as Buffer)

@@ -31,3 +31,3 @@ }

constructor (private readonly hash: Buffer) {
super()
super(schema)
}

@@ -34,0 +34,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc