Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add contracts for parser functions #12

Closed
wants to merge 2 commits into from
Closed

Add contracts for parser functions #12

wants to merge 2 commits into from

Conversation

tshemsedinov
Copy link
Member

No description provided.

lib/parser.js Outdated
// Read parcel from buffer
// Return parcel object
const rest = Buffer.from(buffer, 1, PARCEL_LENGTH);
return rest;
};

const chunk = (buffer) => {
const parcel = (
// Encode handshake structure to Buffer
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Encode parcel structure скорее

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks

@@ -1,41 +1,86 @@
'use strict';

const PROTOCOL_VERSION = 1;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In issue #3 2b for protocol version declared

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We will use writeInt16LE to write this Number value to 2 bytes binary field @mille-nium

@tshemsedinov tshemsedinov removed the request for review from dimanadko May 22, 2018 13:22
tshemsedinov added a commit that referenced this pull request May 22, 2018
@tshemsedinov
Copy link
Member Author

Landed in 4d26244

o-rumiantsev pushed a commit to o-rumiantsev/metacom that referenced this pull request May 22, 2018
tshemsedinov added a commit that referenced this pull request Jun 4, 2018
o-rumiantsev pushed a commit that referenced this pull request Jul 16, 2018
dimanadko pushed a commit to dimanadko/metacom that referenced this pull request Jul 24, 2018
dimanadko pushed a commit to Tariod/metacom that referenced this pull request Jul 31, 2018
dimanadko pushed a commit to Tariod/metacom that referenced this pull request Jul 31, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants