Class: Offering
api/entities/Offering.Offering
Represents an Asset Offering in the Polymesh blockchain
Hierarchy
-
Entity
<UniqueIdentifiers
,HumanReadable
>↳
Offering
Properties
asset
• asset: FungibleAsset
Asset being offered
Defined in
api/entities/Offering/index.ts:74
id
• id: BigNumber
identifier number of the Offering
Defined in
api/entities/Offering/index.ts:69
uuid
• uuid: string
Inherited from
Defined in
Methods
close
▸ close(opts?
): Promise
<GenericPolymeshTransaction
<void
, void
>>
Close the Offering
Parameters
Name | Type |
---|---|
opts? | ProcedureOpts |
Returns
Promise
<GenericPolymeshTransaction
<void
, void
>>
Note
this method is of type NoArgsProcedureMethod, which means you can call close.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it
Defined in
api/entities/Offering/index.ts:174
details
▸ details(): Promise
<OfferingDetails
>
Retrieve the Offering's details
Returns
Promise
<OfferingDetails
>
Note
can be subscribed to, if connected to node using a web socket
Defined in
api/entities/Offering/index.ts:120
▸ details(callback
): Promise
<UnsubCallback
>
Parameters
Name | Type |
---|---|
callback | SubCallback <OfferingDetails > |
Returns
Promise
<UnsubCallback
>
Defined in
api/entities/Offering/index.ts:121
exists
▸ exists(): Promise
<boolean
>
Determine whether this Offering exists on chain
Returns
Promise
<boolean
>
Overrides
Defined in
api/entities/Offering/index.ts:288
freeze
▸ freeze(opts?
): Promise
<GenericPolymeshTransaction
<Offering
, Offering
>>
Freeze the Offering
Parameters
Name | Type |
---|---|
opts? | ProcedureOpts |
Returns
Promise
<GenericPolymeshTransaction
<Offering
, Offering
>>
Note
this method is of type NoArgsProcedureMethod, which means you can call freeze.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it
Defined in
api/entities/Offering/index.ts:184
getInvestments
▸ getInvestments(opts?
): Promise
<ResultSet
<Investment
>>
Retrieve all investments made on this Offering
Parameters
Name | Type | Description |
---|---|---|
opts | Object | - |
opts.size? | BigNumber | page size |
opts.start? | BigNumber | page offset |
Returns
Promise
<ResultSet
<Investment
>>
Note
supports pagination
Note
uses the middleware V2
Defined in
api/entities/Offering/index.ts:236
invest
▸ invest(args
, opts?
): Promise
<GenericPolymeshTransaction
<void
, void
>>
Invest in the Offering
Parameters
Name | Type |
---|---|
args | InvestInOfferingParams |
opts? | ProcedureOpts |
Returns
Promise
<GenericPolymeshTransaction
<void
, void
>>
Note
required roles:
- Purchase Portfolio Custodian
- Funding Portfolio Custodian
Note
this method is of type ProcedureMethod, which means you can call invest.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it
Defined in
api/entities/Offering/index.ts:223
isEqual
▸ isEqual(entity
): boolean
Determine whether this Entity is the same as another one
Parameters
Name | Type |
---|---|
entity | Entity <unknown , unknown > |
Returns
boolean
Inherited from
Defined in
modifyTimes
▸ modifyTimes(args
, opts?
): Promise
<GenericPolymeshTransaction
<void
, void
>>
Modify the start/end time of the Offering
Parameters
Name | Type |
---|---|
args | ModifyOfferingTimesParams |
opts? | ProcedureOpts |
Returns
Promise
<GenericPolymeshTransaction
<void
, void
>>
Throws
if:
- Trying to modify the start time on an Offering that already started
- Trying to modify anything on an Offering that already ended
- Trying to change start or end time to a past date
Note
this method is of type ProcedureMethod, which means you can call modifyTimes.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it
Defined in
api/entities/Offering/index.ts:209
toHuman
▸ toHuman(): HumanReadable
Return the Offering's ID and Asset ticker
Returns
Overrides
Defined in
api/entities/Offering/index.ts:304
unfreeze
▸ unfreeze(opts?
): Promise
<GenericPolymeshTransaction
<Offering
, Offering
>>
Unfreeze the Offering
Parameters
Name | Type |
---|---|
opts? | ProcedureOpts |
Returns
Promise
<GenericPolymeshTransaction
<Offering
, Offering
>>
Note
this method is of type NoArgsProcedureMethod, which means you can call unfreeze.checkAuthorization on it to see whether the signing Account and Identity have the required roles and permissions to run it
Defined in
api/entities/Offering/index.ts:194
generateUuid
▸ Static
generateUuid<Identifiers
>(identifiers
): string
Generate the Entity's UUID from its identifying properties
Type parameters
Name |
---|
Identifiers |
Parameters
Name | Type |
---|---|
identifiers | Identifiers |
Returns
string
Inherited from
Defined in
unserialize
▸ Static
unserialize<Identifiers
>(serialized
): Identifiers
Unserialize a UUID into its Unique Identifiers
Type parameters
Name |
---|
Identifiers |
Parameters
Name | Type | Description |
---|---|---|
serialized | string | UUID to unserialize |
Returns
Identifiers