git.iko.soy/opencode-android
on master help sign in
58 lines 1.8 kB history raw
1// Copyright (c) Facebook, Inc. and its affiliates
2// SPDX-License-Identifier: MIT OR Apache-2.0
4package com.novi.serde;
6import java.math.BigInteger;
8public interface Serializer {
9 void serialize_str(String value) throws SerializationError;
11 void serialize_bytes(Bytes value) throws SerializationError;
13 void serialize_bool(Boolean value) throws SerializationError;
15 void serialize_unit(Unit value) throws SerializationError;
17 void serialize_char(Character value) throws SerializationError;
19 void serialize_f32(Float value) throws SerializationError;
21 void serialize_f64(Double value) throws SerializationError;
23 void serialize_u8(@Unsigned Byte value) throws SerializationError;
25 void serialize_u16(@Unsigned Short value) throws SerializationError;
27 void serialize_u32(@Unsigned Integer value) throws SerializationError;
29 void serialize_u64(@Unsigned Long value) throws SerializationError;
31 void serialize_u128(@Unsigned @Int128 BigInteger value) throws SerializationError;
33 void serialize_i8(Byte value) throws SerializationError;
35 void serialize_i16(Short value) throws SerializationError;
37 void serialize_i32(Integer value) throws SerializationError;
39 void serialize_i64(Long value) throws SerializationError;
41 void serialize_i128(@Int128 BigInteger value) throws SerializationError;
43 void serialize_len(long value) throws SerializationError;
45 void serialize_variant_index(int value) throws SerializationError;
47 void serialize_option_tag(boolean value) throws SerializationError;
49 void increase_container_depth() throws SerializationError;
51 void decrease_container_depth();
53 int get_buffer_offset();
55 void sort_map_entries(int[] offsets);
57 byte[] get_bytes();