-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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 #1772: Default Parameter from Genesis
add InitGenesis fix lint add immutablestore Merge pull request #1775: ConsensusParams in BaseApp add endblocker in params in progress fix errors fix gaiadebug/hack.go finalize rebase to transientstore branch fix error fix lint finalize merging fix synerror in progress in progress add gasconfig in params, restructure fix errors add tests
- Loading branch information
Showing
32 changed files
with
1,054 additions
and
703 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
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
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 |
---|---|---|
@@ -0,0 +1,44 @@ | ||
package store | ||
|
||
import ( | ||
dbm "github.com/tendermint/tendermint/libs/db" | ||
|
||
sdk "github.com/cosmos/cosmos-sdk/types" | ||
) | ||
|
||
type ImmutableStore struct { | ||
dbStoreAdapter | ||
|
||
initialized bool | ||
commitID CommitID | ||
} | ||
|
||
func NewImmutableStore() *ImmutableStore { | ||
return &ImmutableStore{ | ||
dbStoreAdapter: dbStoreAdapter{dbm.NewMemDB()}, | ||
} | ||
} | ||
|
||
func (is *ImmutableStore) Commit() CommitID { | ||
if !is.initialized { | ||
panic("Commit() on not initialized ImmutableStore") | ||
} | ||
is.commitID.Version += 1 | ||
return is.commitID | ||
} | ||
|
||
func (is *ImmutableStore) LastCommitID() CommitID { | ||
return is.commitID | ||
} | ||
|
||
func (is *ImmutableStore) SetPruning(pruning sdk.PruningStrategy) { | ||
return | ||
} | ||
|
||
func (is *ImmutableStore) Set(key, value []byte) { | ||
panic("Set() called on ImmutableStore") | ||
} | ||
|
||
func (is *ImmutableStore) Delete(key []byte) { | ||
panic("Delete() called on ImmutableStore") | ||
} |
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
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.