ICapitalAccountRegistry

Git Source

Interface for capital account registry operations

Defines the standard interface for managing investor capital accounts

Functions

createAccount

Create a new capital account

function createAccount(address investor, InvestorType investorType, uint256 commitment) external;

recordCommitment

Record additional commitment

function recordCommitment(address investor, uint256 amount) external;

recordContribution

Record capital contribution

function recordContribution(address investor, uint256 amount, uint256 callNumber) external;

recordDistribution

Record distribution

function recordDistribution(address investor, uint256 amount, uint256 distributionType) external;

deductManagementFee

Deduct management fee

function deductManagementFee(address investor, uint256 amount) external;

allocateCarriedInterest

Allocate carried interest

function allocateCarriedInterest(address gp, uint256 amount) external;

updatePreferredReturn

Update preferred return

function updatePreferredReturn(address investor, uint256 amount) external;

closeAccount

Close an account

function closeAccount(address investor) external;

getAccount

Get capital account information

function getAccount(address investor) external view returns (CapitalAccount memory);

getAccountEntries

Get account entries

function getAccountEntries(address investor, uint256 offset, uint256 limit)
    external
    view
    returns (AccountEntry[] memory);

getTotalCommitments

Get total commitments

function getTotalCommitments() external view returns (uint256);

getTotalContributions

Get total contributions

function getTotalContributions() external view returns (uint256);

getTotalDistributions

Get total distributions

function getTotalDistributions() external view returns (uint256);

getUnfundedCommitments

Get unfunded commitments

function getUnfundedCommitments() external view returns (uint256);

getInvestorsByType

Get investors by type

function getInvestorsByType(InvestorType investorType) external view returns (address[] memory);

calculateOwnershipPercentage

Calculate ownership percentage

function calculateOwnershipPercentage(address investor) external view returns (uint256);

calculateProRataShare

Calculate pro-rata share

function calculateProRataShare(address investor, uint256 totalAmount) external view returns (uint256);

isInvestor

Check if address is investor

function isInvestor(address account) external view returns (bool);

getActiveInvestorCount

Get active investor count

function getActiveInvestorCount() external view returns (uint256);

Events

AccountCreated

Emitted when a new capital account is created

event AccountCreated(address indexed investor, InvestorType investorType, uint256 commitment);

CapitalCommitted

Emitted when capital is committed

event CapitalCommitted(address indexed investor, uint256 amount);

CapitalContributed

Emitted when capital is contributed

event CapitalContributed(address indexed investor, uint256 amount, uint256 callNumber);

DistributionRecorded

Emitted when distribution is recorded

event DistributionRecorded(address indexed investor, uint256 amount, uint256 distributionType);

ManagementFeeDeducted

Emitted when management fee is deducted

event ManagementFeeDeducted(address indexed investor, uint256 amount);

CarriedInterestAllocated

Emitted when carried interest is allocated

event CarriedInterestAllocated(address indexed gp, uint256 amount);

AccountClosed

Emitted when an account is closed

event AccountClosed(address indexed investor);

Structs

CapitalAccount

Capital account information

struct CapitalAccount {
    address investor;
    InvestorType investorType;
    uint256 commitment;
    uint256 totalContributions;
    uint256 totalDistributions;
    uint256 unfundedCommitment;
    uint256 preferredReturn;
    uint256 profitShare;
    bool isActive;
}

AccountEntry

Account entry for audit trail

struct AccountEntry {
    uint256 timestamp;
    AccountEntryType entryType;
    uint256 amount;
    uint256 balance;
    string description;
}

Enums

InvestorType

Types of investors

enum InvestorType {
    LP,
    GP
}

AccountEntryType

Types of account entries

enum AccountEntryType {
    COMMITMENT,
    CONTRIBUTION,
    DISTRIBUTION,
    FEE,
    CARRY
}

Last updated

Was this helpful?