@@ -28,6 +28,7 @@ use spacetimedb_primitives::TableId;
2828use spacetimedb_sats:: {
2929 de:: { Deserialize , Error } ,
3030 impl_deserialize, impl_serialize, impl_st,
31+ raw_identifier:: RawIdentifier ,
3132 ser:: Serialize ,
3233 AlgebraicType , SpacetimeType ,
3334} ;
@@ -151,7 +152,7 @@ impl<Args> ClientMessage<Args> {
151152#[ sats( crate = spacetimedb_lib) ]
152153pub struct CallReducer < Args > {
153154 /// The name of the reducer to call.
154- pub reducer : Box < str > ,
155+ pub reducer : RawIdentifier ,
155156 /// The arguments to the reducer.
156157 ///
157158 /// In the wire format, this will be a [`Bytes`], BSATN or JSON encoded according to the reducer's argument schema
@@ -312,7 +313,7 @@ pub struct OneOffQuery {
312313/// Parametric over the argument type to enable [`ClientMessage::map_args`].
313314pub struct CallProcedure < Args > {
314315 /// The name of the procedure to call.
315- pub procedure : Box < str > ,
316+ pub procedure : RawIdentifier ,
316317 /// The arguments to the procedure.
317318 ///
318319 /// In the wire format, this will be a [`Bytes`], BSATN or JSON encoded according to the reducer's argument schema
@@ -384,7 +385,7 @@ pub struct SubscribeRows<F: WebsocketFormat> {
384385 /// The table ID of the query.
385386 pub table_id : TableId ,
386387 /// The table name of the query.
387- pub table_name : Box < str > ,
388+ pub table_name : RawIdentifier ,
388389 /// The BSATN row values.
389390 pub table_rows : TableUpdate < F > ,
390391}
@@ -588,7 +589,7 @@ pub struct ReducerCallInfo<F: WebsocketFormat> {
588589 /// We should consider not sending this at all and instead
589590 /// having a startup message where the name <-> id bindings
590591 /// are established between the host and the client.
591- pub reducer_name : Box < str > ,
592+ pub reducer_name : RawIdentifier ,
592593 /// The numerical id of the reducer that was called.
593594 pub reducer_id : u32 ,
594595 /// The arguments to the reducer, encoded as BSATN or JSON according to the reducer's argument schema
@@ -653,7 +654,7 @@ pub struct TableUpdate<F: WebsocketFormat> {
653654 ///
654655 /// NOTE(centril, 1.0): we might want to remove this and instead
655656 /// tell clients about changes to table_name <-> table_id mappings.
656- pub table_name : Box < str > ,
657+ pub table_name : RawIdentifier ,
657658 /// The sum total of rows in `self.updates`,
658659 pub num_rows : u64 ,
659660 /// The actual insert and delete updates for this table.
@@ -668,7 +669,7 @@ pub struct SingleQueryUpdate<F: WebsocketFormat> {
668669}
669670
670671impl < F : WebsocketFormat > TableUpdate < F > {
671- pub fn new ( table_id : TableId , table_name : Box < str > , update : SingleQueryUpdate < F > ) -> Self {
672+ pub fn new ( table_id : TableId , table_name : RawIdentifier , update : SingleQueryUpdate < F > ) -> Self {
672673 Self {
673674 table_id,
674675 table_name,
@@ -677,7 +678,7 @@ impl<F: WebsocketFormat> TableUpdate<F> {
677678 }
678679 }
679680
680- pub fn empty ( table_id : TableId , table_name : Box < str > ) -> Self {
681+ pub fn empty ( table_id : TableId , table_name : RawIdentifier ) -> Self {
681682 Self {
682683 table_id,
683684 table_name,
@@ -746,7 +747,7 @@ pub struct OneOffQueryResponse<F: WebsocketFormat> {
746747#[ sats( crate = spacetimedb_lib) ]
747748pub struct OneOffTable < F : WebsocketFormat > {
748749 /// The name of the table.
749- pub table_name : Box < str > ,
750+ pub table_name : RawIdentifier ,
750751 /// The set of rows which matched the query, encoded as BSATN or JSON according to the table's schema
751752 /// and the client's requested protocol.
752753 ///
0 commit comments