G-Derivatives are Databases of Balances and Prices with extra Scalability (interfaces).
a special ERC1155 contract
Balances
Acts as a Database for the amount of staked Ether that is represented by multiple Maintainers.
Balances for the depositors are tracked with a predetermined ID. IDs are the main separators of the different types of gETH, thus different maintainers.
Balances can be directly changed by Interfaces.
Anyone can disable the access of the interfaces by simply using the avoidInterfaces function!
Pricing
The balance of users, doesn’t change while the amount of the underlying tokens increase over time thanks to Staking Rewards.
Every different ID of gETH has a different _pricePerShare value.
_pricePerShare
Basically, a variable that represents the equivalent of 1 gETH, in terms of underlying Ether.
_pricePerShare is used by Geode on minting / burning operations, and can be used by other contracts with peace of mind.