-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1251 from demergent-labs/functional_syntax_audio_…
…recorder Functional syntax audio recorder
- Loading branch information
Showing
20 changed files
with
634 additions
and
496 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,5 @@ | ||
import { blob, Principal, Service, update } from '../../src/lib_functional'; | ||
|
||
export const managementCanister = Service( | ||
{ | ||
raw_rand: update([], blob) | ||
}, | ||
Principal.fromText('aaaaa-aa') | ||
); | ||
export const managementCanister = Service({ | ||
raw_rand: update([], blob) | ||
})(Principal.fromText('aaaaa-aa')); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,21 @@ | ||
type rec_0 = record {id:principal; username:text; recordingIds:vec principal; createdAt:nat64}; | ||
type rec_1 = record {id:principal; username:text; recordingIds:vec principal; createdAt:nat64}; | ||
type rec_2 = record {id:principal; username:text; recordingIds:vec principal; createdAt:nat64}; | ||
type rec_3 = record {id:principal; username:text; recordingIds:vec principal; createdAt:nat64}; | ||
type rec_4 = variant {RecordingDoesNotExist:principal; UserDoesNotExist:principal}; | ||
type rec_5 = record {id:principal; audio:vec nat8; userId:principal; name:text; createdAt:nat64}; | ||
type rec_4 = record {id:principal; username:text; recordingIds:vec principal; createdAt:nat64}; | ||
type rec_5 = record {id:principal; username:text; recordingIds:vec principal; createdAt:nat64}; | ||
type rec_6 = variant {RecordingDoesNotExist:principal; UserDoesNotExist:principal}; | ||
type rec_7 = record {id:principal; audio:vec nat8; userId:principal; name:text; createdAt:nat64}; | ||
type rec_8 = record {id:principal; audio:vec nat8; userId:principal; name:text; createdAt:nat64}; | ||
type rec_8 = variant {RecordingDoesNotExist:principal; UserDoesNotExist:principal}; | ||
type rec_9 = record {id:principal; audio:vec nat8; userId:principal; name:text; createdAt:nat64}; | ||
type rec_10 = variant {RecordingDoesNotExist:principal; UserDoesNotExist:principal}; | ||
type rec_10 = record {id:principal; audio:vec nat8; userId:principal; name:text; createdAt:nat64}; | ||
type rec_11 = record {id:principal; audio:vec nat8; userId:principal; name:text; createdAt:nat64}; | ||
type rec_12 = variant {RecordingDoesNotExist:principal; UserDoesNotExist:principal}; | ||
service: () -> { | ||
createUser: (text) -> (rec_0); | ||
readUsers: () -> (vec rec_1) query; | ||
readUserById: (principal) -> (opt rec_2) query; | ||
deleteUser: (principal) -> (variant {Ok:rec_3; Err:rec_4}); | ||
createRecording: (vec nat8, text, principal) -> (variant {Ok:rec_5; Err:rec_6}); | ||
readRecordings: () -> (vec rec_7) query; | ||
readRecordingById: (principal) -> (opt rec_8) query; | ||
deleteRecording: (principal) -> (variant {Ok:rec_9; Err:rec_10}); | ||
createUser: (text) -> (rec_2); | ||
readUsers: () -> (vec rec_3) query; | ||
readUserById: (principal) -> (opt rec_4) query; | ||
deleteUser: (principal) -> (variant {Ok:rec_5; Err:rec_6}); | ||
createRecording: (vec nat8, text, principal) -> (variant {Ok:rec_7; Err:rec_8}); | ||
readRecordings: () -> (vec rec_9) query; | ||
readRecordingById: (principal) -> (opt rec_10) query; | ||
deleteRecording: (principal) -> (variant {Ok:rec_11; Err:rec_12}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.