Skip to content

Commit

Permalink
feat(indexer): ♻️ rename ApplicationStateSchema -> StateSchema
Browse files Browse the repository at this point in the history
  • Loading branch information
jasonboukheir committed Oct 3, 2021
1 parent 04227b9 commit 7b02f70
Show file tree
Hide file tree
Showing 9 changed files with 24 additions and 24 deletions.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public struct Account
public Optional<ulong> ApplicationsTotalExtraPages;

[AlgoApiField("apps-total-schema", null)]
public Optional<ApplicationStateSchema> ApplicationsTotalSchema;
public Optional<StateSchema> ApplicationsTotalSchema;

[AlgoApiField("assets", null)]
public AssetHolding[] Assets;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public struct ApplicationLocalState
public Optional<ulong> OptedInAtRound;

[AlgoApiField("schema", null)]
public ApplicationStateSchema Schema;
public StateSchema Schema;

public bool Equals(ApplicationLocalState other)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@ public struct ApplicationParams
public TealKeyValue[] GlobalState;

[AlgoApiField("global-state-schema", null)]
public Optional<ApplicationStateSchema> GlobalStateSchema;
public Optional<StateSchema> GlobalStateSchema;

[AlgoApiField("local-state-schema", null)]
public Optional<ApplicationStateSchema> LocalStateSchema;
public Optional<StateSchema> LocalStateSchema;

public bool Equals(ApplicationParams other)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,14 +59,14 @@ public Address[] ForeignAssets
}

[AlgoApiField(null, "apgs")]
public Optional<ApplicationStateSchema> GlobalStateSchema
public Optional<StateSchema> GlobalStateSchema
{
get => ApplicationCallParams.GlobalStateSchema;
set => ApplicationCallParams.GlobalStateSchema = value;
}

[AlgoApiField(null, "apls")]
public Optional<ApplicationStateSchema> LocalStateSchema
public Optional<StateSchema> LocalStateSchema
{
get => ApplicationCallParams.LocalStateSchema;
set => ApplicationCallParams.LocalStateSchema = value;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@
namespace AlgoSdk
{
[AlgoApiObject]
public struct ApplicationStateSchema
: IEquatable<ApplicationStateSchema>
public struct StateSchema
: IEquatable<StateSchema>
{
[AlgoApiField("num-byte-slice", "nbs")]
public ulong NumByteSlices;

[AlgoApiField("num-uint", "nui")]
public ulong NumUints;

public bool Equals(ApplicationStateSchema other)
public bool Equals(StateSchema other)
{
return NumByteSlices.Equals(other.NumByteSlices)
&& NumUints.Equals(other.NumUints)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ namespace AlgoSdk
[AlgoApiFormatter(typeof(OptionalFormatter<ulong>))]
[AlgoApiFormatter(typeof(OptionalFormatter<Address>))]
[AlgoApiFormatter(typeof(OptionalFormatter<AccountParticipation>))]
[AlgoApiFormatter(typeof(OptionalFormatter<ApplicationStateSchema>))]
[AlgoApiFormatter(typeof(OptionalFormatter<StateSchema>))]
public struct Optional<T>
: IEquatable<Optional<T>>
where T : struct, IEquatable<T>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,12 +118,12 @@ public Address[] ForeignAssets
get => @params.ForeignAssets;
set => @params.ForeignAssets = value;
}
public Optional<ApplicationStateSchema> GlobalStateSchema
public Optional<StateSchema> GlobalStateSchema
{
get => @params.GlobalStateSchema;
set => @params.GlobalStateSchema = value;
}
public Optional<ApplicationStateSchema> LocalStateSchema
public Optional<StateSchema> LocalStateSchema
{
get => @params.LocalStateSchema;
set => @params.LocalStateSchema = value;
Expand Down Expand Up @@ -209,10 +209,10 @@ public struct Params
public Address[] ForeignAssets;

[AlgoApiField("global-state-schema", "global-state-schema")]
public Optional<ApplicationStateSchema> GlobalStateSchema;
public Optional<StateSchema> GlobalStateSchema;

[AlgoApiField("local-state-schema", "local-state-schema")]
public Optional<ApplicationStateSchema> LocalStateSchema;
public Optional<StateSchema> LocalStateSchema;

[AlgoApiField("extra-program-pages", "epp")]
public Optional<ulong> ExtraProgramPages;
Expand Down

0 comments on commit 7b02f70

Please sign in to comment.