Invention content
This specification also proposes a kind of assets management method, including:
The node device of block chain receives assets object convert requests;Wherein, the assets object convert requests include
Second Asset Type of the assets object and request conversion of the first Asset Type converted;
In response to the assets object convert requests, call publication on the block chain with second Asset Type
The assets object of first Asset Type is converted to the assets object of second Asset Type by corresponding contract object;
The assets object of transformed second Asset Type is added to the assets for holding first Asset Type
The target object of object.
Optionally, first for converting Asset Type is stated in the contract object executes program, for creating money
Produce the assets pair of assets object and second Asset Type that the second of object executes program and first Asset Type
Conversion rule as between;
It is described to call with second Asset Type corresponding contract object of the publication on the block chain, by described the
The assets object that the assets object of one Asset Type is converted to second Asset Type includes:
It calls described in being stated in contract object corresponding with second Asset Type of the publication on the block chain
First executes program, and the assets object of first Asset Type is scaled the second assets class based on conversion rule
The assets object of type;And
It further calls and is stated in contract object corresponding with second Asset Type of the publication on the block chain
It is described second execute program, create the assets object of second Asset Type conversed.
Optionally, the conversion rule includes:
The assets object of first Asset Type is scaled to the assets object for being worth identical second Asset Type.
Optionally, the assets object by transformed second Asset Type, which is added to, holds first assets
The target object of the assets object of type, including:
The money of first Asset Type is removed from the target object of assets object for holding first Asset Type
The address information of the assets object of first Asset Type is added to the publication contract object by the address information for producing object
The assets of target members' assets object for holding second Asset Type hold object;And by the transformed institute
The assets object for stating the second Asset Type is added to the target object.
Optionally, the assets object by transformed second Asset Type, which is added to, holds first assets
The target object of the assets object of type, including:
The assets of first Asset Type in the target object of the assets object of first Asset Type will be held
The address information of object is revised as the address information of the assets object of transformed second Asset Type.
Optionally, the object that the block chain is supported includes address field;Described address field is for safeguarding that object is held
Assets object address information.
Optionally, the object that the block chain is supported further includes code field;The code field is for safeguarding to onomatopoeia
The relevant execution code of bright execution program.
Optionally, the assets hold object and include:
The assets specified by the target members hold object;Alternatively,
And the assets corresponding with the target members stated in the corresponding contract object of second Asset Type are held
Object.
Optionally, the object that the block chain is supported includes account object, contract object and assets object;
The object of holding assets object includes any in account object, contract object and assets object.
Optionally, the block chain is alliance's chain;Target members in the block chain are to have money in alliance's chain
Produce the allied member of Object Creation permission.
This specification also proposes a kind of asset management device, including:
Receiving module receives assets object convert requests;Wherein, the assets object convert requests include being converted
Second Asset Type of the assets object and request conversion of the first Asset Type;
Conversion module, in response to the assets object convert requests, call publication on the block chain with described the
The assets object of first Asset Type is converted to second Asset Type by the corresponding contract object of two Asset Types
Assets object;
The assets object of transformed second Asset Type is added to and holds the first assets class by add module
The target object of the assets object of type.
Optionally, first for converting Asset Type is stated in the contract object executes program, for creating money
Produce the assets pair of assets object and second Asset Type that the second of object executes program and first Asset Type
Conversion rule as between;
It is described to call with second Asset Type corresponding contract object of the publication on the block chain, by described the
The assets object that the assets object of one Asset Type is converted to second Asset Type includes:
It calls described in being stated in contract object corresponding with second Asset Type of the publication on the block chain
First executes program, and the assets object of first Asset Type is scaled the second assets class based on conversion rule
The assets object of type;And
It further calls and is stated in contract object corresponding with second Asset Type of the publication on the block chain
It is described second execute program, create the assets object of second Asset Type conversed.
Optionally, the conversion rule includes:
The assets object of first Asset Type is scaled to the assets object for being worth identical second Asset Type.
Optionally, the add module:
The money of first Asset Type is removed from the target object of assets object for holding first Asset Type
The address information of the assets object of first Asset Type is added to the publication contract object by the address information for producing object
The assets of target members' assets object for holding second Asset Type hold object;And by the transformed institute
The assets object for stating the second Asset Type is added to the target object.
Optionally, the add module:
The assets of first Asset Type in the target object of the assets object of first Asset Type will be held
The address information of object is revised as the address information of the assets object of transformed second Asset Type.
Optionally, the object that the block chain is supported includes address field;Described address field is for safeguarding that object is held
Assets object address information.
Optionally, the object that the block chain is supported further includes code field;The code field is for safeguarding to onomatopoeia
The relevant execution code of bright execution program.
Optionally, the assets hold object and include:
The assets specified by the target members hold object;Alternatively,
And the assets corresponding with the target members stated in the corresponding contract object of second Asset Type are held
Object.
Optionally, the object that the block chain is supported includes account object, contract object and assets object;
The object of holding assets object includes any in account object, contract object and assets object.
Optionally, the block chain is alliance's chain;Target members in the block chain are to have money in alliance's chain
Produce the allied member of Object Creation permission.
This specification also proposes a kind of electronic equipment, including:
Processor;
Memory for storing machine-executable instruction;
Wherein, the control logic pair with the asset management based on block chain stored by reading and executing the memory
The machine-executable instruction answered, the processor are prompted to:
Receive assets object convert requests;Wherein, the assets object convert requests include the first assets converted
Second Asset Type of the assets object and request conversion of type;
In response to the assets object convert requests, call publication on the block chain with second Asset Type
The assets object of first Asset Type is converted to the assets object of second Asset Type by corresponding contract object;
The assets object of transformed second Asset Type is added to the assets for holding first Asset Type
The target object of object.
By above example, user can initiate assets object convert requests, be stated in assets object convert requests
The assets object for the first Asset Type converted, and the second Asset Type of conversion is asked, by calling publication in block
The assets object for the first Asset Type converted is converted to and is asked by the contract object corresponding with the second Asset Type on chain
The assets object of the second Asset Type of conversion is sought, then the assets object of transformed second Asset Type is added to and is held
In the target object of the assets object of first Asset Type, so as to realize assets with the real world, area is transformed into
Digital asset on block chain is held, and relies on the type conversion of the online completion assets of block chain.
Specific implementation mode
It is intended to open one kind in this specification, the technical solution of the type conversion of assets object is completed in block chain.
When realizing, the target members in block chain can issue the Asset Type with assets object on block chain in advance
Corresponding contract object (intelligent contract).Wherein, the above-mentioned contract object of establishment is for being managed assets object, access area
The user of block chain can create an assets object, and in area by way of calling above-mentioned contract object on block chain
The online management of assets object held is completed on block chain.
On the one hand, when creating assets object, the user for accessing block chain can initiate an assets object to block chain
Request to create completes the establishment of assets object, then by the address information of the assets object of establishment to call above-mentioned contract object
It is added to the target object for holding the assets object;For example, can be stated in advance in contract object for creating assets object
Execution program, in such a case, it is possible to above-mentioned for creating the execution program of assets object by calling, to complete assets
The establishment of object.
On the other hand, the user of access block chain, can when needing to change the assets object progress Asset Type dress held
To initiate an assets object convert requests to block chain;And the node device in block chain receive the assets object conversion ask
After asking, the assets object convert requests can be responded, by call publication on block chain with above-mentioned second Asset Type pair
The assets object of above-mentioned first Asset Type is converted to the assets object of above-mentioned second Asset Type, so by the contract object answered
The assets object of transformed above-mentioned second Asset Type is added to the assets object for holding above-mentioned first Asset Type afterwards
Target object completes the Asset Type conversion for the assets object held.
By above example, user can initiate assets object convert requests, be stated in assets object convert requests
The assets object for the first Asset Type converted, and the second Asset Type of conversion is asked, by calling publication in block
The assets object for the first Asset Type converted is converted to and is asked by the contract object corresponding with the second Asset Type on chain
The assets object of the second Asset Type of conversion is sought, then the assets object of transformed second Asset Type is added to and is held
In the target object of the assets object of first Asset Type, so as to realize assets with the real world, area is transformed into
Digital asset on block chain is held, and relies on the type conversion of the online completion assets of block chain.
This specification is described below by specific embodiment and in conjunction with specific application scenarios.
Referring to FIG. 1, Fig. 1 is a kind of assets management method that one embodiment of this specification provides, it is applied in block chain
Node device, execute following steps:
Step 102, the node device of block chain receives assets object convert requests;Wherein, the assets object conversion
Request includes the second Asset Type of the assets object and request conversion for the first Asset Type converted;
Step 104, in response to the assets object convert requests, call publication on the block chain with described second
The assets object of first Asset Type, is converted to the money of second Asset Type by the corresponding contract object of Asset Type
Produce object;
Step 106, the assets object of transformed second Asset Type is added to and holds the first assets class
The target object of the assets object of type.
In the block chain of this specification description, can specifically include can cover appointing for assets object in supported object
The block chain network for type of anticipating.
For example, in traditional block chain, the object supported only includes usually account object and contract object, and at this
In specification, the object that can be supported block chain is extended, in such as account object and conjunction of the existing support of block chain
About on the basis of object, a kind of assets object is further expanded out.
Wherein, it should be noted that the type of the block chain of this specification description can be connection without being particularly limited to
Alliance's chain, other types of block chain (such as privately owned chain, publicly-owned chain etc.) that can also be other than alliance's chain.
Above-mentioned contract object can specifically include and be issued in block chain, and in block chain by the target members in block chain
Distributed data base (i.e. block chain account book) in include, the assets object for supporting block chain be managed intelligence close
About program.The user for accessing block chain can create an assets by way of calling above-mentioned contract object on block chain
Object, and complete on block chain the online management of assets object held.
For example, in one example, above-mentioned block chain can be specifically one by several financial machines as allied member
Alliance's chain that structure is constituted, in this case, the target members in block chain can be then to have assets object wound in alliance's chain
Build the financial institution as allied member of permission.A distributed intelligent contract platform can be built by alliance's chain,
The operator of the intelligence contract platform, the object type that can be supported the intelligence contract platform is extended, in existing branch
On the basis of such as account object and contract object held, a kind of assets object is further expanded out so that as allied member
Financial institution, can be created in platform a kind of new by issuing the form of intelligent contract (contract object) on block chain
The Asset Type of increasing, so access block chain user, can by call the intelligence contract create an assets object with
And complete the online management for the assets object held.
Wherein, it should be noted that in the present specification, the request initiated on block chain of user of access block chain
Type can refer to specifically the transaction (transfer) employed in traditional block chain.
For example, the user of access block chain can be by initiating a friendship for creating assets object in block chain
Easily, it has issued contract object in block chain to call and completes assets Object Creation;Alternatively, can also be by block chain
A newer transaction of state for completing assets object is initiated, to call the contract object issued in block chain to complete
The Asset State of assets object updates.
Certainly, the type for the request that the user of access block chain initiates on block chain, can also be specifically other than transaction
, instruction, message of the data structure with standard of other forms etc., in the present specification without being particularly limited to.With
Under each embodiment in, book will be illustrated for accessing request that the user of block chain initiates on block chain and be transaction.
Above-mentioned assets object may include intellectual capital object;Intellectual capital object is for safeguarding intellectual capital, the intelligence
Assets correspond to user in any type of real estate with the real world, and by intellectual capital object the intelligence are provided
Production capacity is enough suitable for being handled block chain, for example especially suitable for by modes such as intelligent contracts in block chain to this
Intellectual capital object is handled.Wherein, intellectual capital correspond to user real estate with the real world type, this
Without being particularly limited in specification;
For example, by taking above-mentioned block chain is the alliance's chain being made of several financial institutions as an example, in practical applications, Yong Huren
Assets under the line of meaning form;For example, fund, house property, stock, loan agreement, bill, accounts receivable etc. can be by managing the connection
The financial institution of node device on alliance's chain is packaged into the form of digital asset, creates and issues the distribution in alliance's chain
In database.
Below by way of specific embodiment, and combine " block chain object extension ", " contract object publishing ", " assets object
Create " and " conversion of assets object type ", the technical solution of this specification is described in detail.
1) block chain object extension
In the present specification, the operator of above-mentioned block chain can support block chain when building block chain network
Object be extended.
In traditional block chain (such as ether mill), the object that block chain is supported usually only includes account object and conjunction
About two class of object.And in the present specification, the object that can be supported block chain is extended, in existing account object and conjunction
An assets object is about further expanded out on the basis of object.
I.e. in the present specification, the object that above-mentioned block chain is supported may include account object, contract object and assets
The three classes such as object.In this way, for access block chain user for, in addition to can be completed on block chain account,
Other than the establishment of intelligent contract, a stroke numeral assets can also be created on block chain, and then can be by money with the real world
Production transforms into digital asset of the publication on block chain.
In a kind of embodiment shown, the object that above-mentioned block chain is supported still can be by following four classes attribute
Field is constituted:
Balance fields (address field), in traditional block chain (such as ether mill), the usual table of Balance fields
Show " remaining sum ", is used to indicate the quantity for the token that object is held.And in the present specification, it can be to the meaning of Balance fields
It is extended, the address information for the assets object for no longer indicating " remaining sum ", but being used to safeguard that object is held.Wherein, in reality
In, the address information of multiple assets object can be safeguarded in Balance fields.
When realizing, account object illustrated above, contract object and assets object can be by Balance words
The address information that assets object is added in section, to hold assets object corresponding with the address information.I.e. in the present specification, it removes
Other than account object and contract object illustrated above, assets object itself can also hold fictitious assets.
Storage fields, the various states (such as account status, contract state, Asset State etc.) for safeguarding object.
For example, by taking assets object as an example, the financial institution of the assets object is issued, or other had pair by what the financial institution specified
The executor for the permission that assets object is updated, can be by changing the content in Storage fields, to update the assets pair
The state of elephant.For example, by taking above-mentioned assets object is the digital asset for being packaged into the loan agreement assets under user's line as an example, when
The daily loan state of honouring an agreement of the user changes, and issues the financial institution of the assets object, or referred to by the financial institution
Fixed other executors with the permission being updated to assets object, the state that can be honoured an agreement based on the daily loan of user are become
Change, update is synchronized to the content in the Storage fields in the corresponding assets object of the digital asset.
Code fields, for safeguard object statement relevant the executions code of execution program (such as with it is code dependent respectively
The executable method of kind).I.e. in the present specification, for account object illustrated above, contract object and assets object,
Relevant execution program can be stated in object.
For example, for for the contract object that is managed to assets object, the assets that are managed with the contract object
The relevant any form of operation of object, can be in the form of executing program, in the Code fields of the contract object in advance
Statement subsequently can execute program, to complete corresponding operation by directly invoking these;For example, for assets object into
The execution program stated in the contract object of row management usually may include for creating the execution program of assets object, update
The execution program of assets object, execution program of assets transfer object, etc..
Wherein, it should be noted that above-mentioned Code fields are held in addition to that can safeguard that the execution program of object statement is relevant
Other than line code, such as call address of contract object can also be safeguarded, be the calling for needing to transmit calling the contract object
Parameter, etc..
Nonce fields, for safeguarding the counting for preventing block chain from Replay Attack occurs.The counting can be usually used for one
Prevent block chain from the random number or pseudo random number of Replay Attack occurs.
2) contract object publishing
In a kind of embodiment shown, above-mentioned block chain can be specifically one by several gold as allied member
Melt alliance's chain of mechanism composition.In this case, the target members in block chain can be then to have assets pair in alliance's chain
The financial institution as allied member as creating permission.
A distributed intelligent contract platform can be built by alliance's chain, and there is assets object in alliance's chain
The financial institution of permission is created, can be created in platform by the form of the intelligent contract (contract object) of publication on alliance's chain
Build a kind of newly-increased Asset Type.
When realizing, each financial institution in alliance's chain can be registered as the allied member of alliance's chain first, obtain connection
A pair of of the public key and private key that alliance's chain returns.Public key is by the account address as each financial institution in alliance on the face;Private key is by conduct
Unique key of each financial institution's operation account.It secondly, can be by alliance's chain for each financial institution for the chain that coalizes
Operator carrys out the permission that unified authorization creates assets object.It, can be with after financial institution achieves the permission for creating assets object
Based on actual demand, an intelligent contract is created and issued in alliance's chain, a kind of newly-increased Asset Type is created.
Wherein, financial institution issues the detailed process of intelligent contract in alliance's chain, no longer carries out in the present specification detailed
It states, those skilled in the art can refer to record in the related technology;
For example, in practical applications, financial institution can issue the shape of a transaction to alliance's chain based on the private key held
Formula creates the intelligent contract completed to alliance's chain publication.And Lian Zhongge allied members of alliance receive by the node device of management
To other financial institutions issue transaction when, can be based on the common recognition algorithm of alliance's chain, in alliance's chain in nearest a period of time
The transaction of publication carries out common recognition processing, and after the completion of common recognition is handled, and the intelligent contract which issues is included to alliance's chain
Distributed data base in.Wherein, common recognition of the common recognition algorithm and alliance's chain of the support of above-mentioned alliance's chain based on common recognition algorithm
Processing procedure is no longer described in detail in the present specification, and those skilled in the art can refer to record in the related technology.
In the present specification, with newly-increased Asset Type corresponding intelligent contract of financial institution's publication in alliance's chain
In, the relevant execution program of Asset Type corresponding with the intelligence contract can be stated in advance.These execution journeys stated in advance
Sequence can specifically carry in the Code fields of contract object corresponding with the intelligence contract.
In a kind of embodiment shown, financial institution's publication is corresponding with newly-increased Asset Type in alliance's chain
The execution program stated in intelligent contract may include the execution program for creating assets object, and for transferring assets
The execution program of object.For the user of access alliance chain, the api interface that can be provided by calling alliance chain, Xiang Lian
Alliance's chain issues the transaction after being signed based on the private key held, and the execution program stated in above-mentioned intelligent contract is called, to create
It builds fictitious assets and completes the online transfer for the fictitious assets held.
Certainly, that is stated in intelligent contract corresponding with newly-increased Asset Type of financial institution's publication in alliance's chain holds
Line program, in addition to it is illustrated above for the execution program for the object that creates and transfer assets other than, can also include and above-mentioned money
Produce the relevant other execution programs of object;For example, to the execution program that assets object is updated, in the present specification no longer into
Row enumerates.
3) assets Object Creation
In the present specification, for need access block chain user, can also in advance in alliance's chain carry out user's note
Volume obtains a pair of of public key and private key that alliance's chain returns.After the completion of registration, alliance's chain can be that user's establishment one is corresponding
Account object.
And for the user that registration is completed, the api interface that can be provided by alliance's chain is based on to alliance's chain publication
The transaction for asking establishment assets object after the private key signature held.
And the node device in the alliance's chain docked with the user that the registration is completed, it is issued based on private key receiving the user
The transaction after, the corresponding public key of private key that can be held first based on the user carries out authentication to the user;For example,
In practical applications, user can sign to the transaction of initiation based on the private key held, the node device base in block chain
In the corresponding public key of private key that the user holds, signature is authenticated;If signature authentication passes through, it is directed to the user's at this time
Authentication passes through.
After authentication passes through, common recognition processing can be carried out to the transaction received in a period of time based on common recognition algorithm,
And after the completion of common recognition is handled, the transaction can be executed, to determine that user asks the type (alliance of the assets object created
The contract object of the different assets object type of a variety of correspondences may have been issued in chain, and what user asked to create may be wherein
A certain type assets object).
For example, in one implementation, in the transaction of user based on the private key publication held, it can be stated that
The type of the assets object created is asked, and receives the node device of the transaction, it can be based on the letter stated in the transaction
Breath, come determine the user this request create assets object type.
After the node device determines that the user asks the assets object type created, it can further inquire and send out
With user requested assets object type corresponding contract object of the cloth in alliance's chain, can then be based on the contract pair
The call address of elephant completes assets object to call the execution program for creating assets object stated in the contract object
Establishment.
For example, in one implementation, in the transaction of user based on the private key publication held, institute can also be carried
Ask the relevant parameter of assets object created;For example, the parameters such as number of assets that request creates.Above-mentioned node device exists
When calling above-mentioned contract object, these parameters can be passed to as call parameters stated in above-mentioned contract object for creating
The execution program for building assets object, is called execution, to complete the establishment of assets object.
In a kind of embodiment shown, when by process illustrated above, being created for above-mentioned user and complete assets pair
As rear, above-mentioned node device will can also further create the address information for the assets object completed, and be added to and hold the money
In the Balance fields for producing the target object of object.
Wherein, in the present specification, the generating process of the address information of above-mentioned assets object, in the present specification without
It is particularly limited to;For example, in one implementation, the address information of assets object can be specifically to create the money for request
The transaction content for producing object carries out Hash calculation, an obtained cryptographic Hash.
In a kind of embodiment shown, finally hold create complete the assets object target object, including with
Under two kinds of situations showing:
In one case, finally hold the target object for creating the assets object completed, can be specified by user
For holding the target object of the assets object.
For example, when realizing, user can be in the request of publication creates the transaction of assets object, and statement in advance can be held
There is the target object of newly-built assets object;Alternatively, specified holding can be created that by user by way of being informed under line
Assets object target object, inform issue the assets object financial institution.
Can also be above-mentioned contract in another case, finally holding the target object for creating the assets object completed
The target object for holding the assets object stated in advance in object.I.e. above-mentioned financial institution is issuing the contract object
When, it can state the target pair that can hold the assets object by calling the contract Object Creation to go out in advance in contract object
As.
For example, above-mentioned financial institution when issuing above-mentioned contract object, can state one in advance in the contract object
The white list that the target object of the assets object by calling the contract Object Creation to go out can be held, only hits the white list
Target object, the assets object for calling above-mentioned contract Object Creation to go out can be held.
In a kind of embodiment shown, the assets object being created that may finally be held, can specifically include above-mentioned
Any one in account object, contract object and assets object that alliance's chain is supported.I.e. in the present specification, above-mentioned alliance
Account object, contract object and the assets object that chain is supported can be with holding assets objects.For the assets object being created that,
It can specified by user, or stated in contract object, in above-mentioned account object, contract object and assets object
Hold in the object of any one type.
For example, in one example, assets object A can be appointed as holding the mesh for the assets object B being created that by user
Object is marked, and then can be completed by being added to the address information of assets object B in the Balance fields of assets object A
The packing of assets object A and assets object B are handled.
4) assets object type is converted
In the present specification, for the user that registration is completed, in addition to the api interface that can be provided by alliance's chain,
To alliance's chain publication based on the transaction for asking establishment assets object after the private key signature held, to initiate assets object wound
It, in practical applications, can also be by above-mentioned api interface, after being issued to alliance's chain based on the private key signature held other than building
For the transaction of assets object conversion, type conversion is carried out to the assets object held.
And the node device in the alliance's chain docked with the user that the registration is completed, it is issued based on private key receiving the user
The transaction after, the corresponding public key of private key that can also be held first based on the user carries out authentication to the user;When
After authentication passes through, common recognition processing can be carried out to the transaction received in a period of time based on common recognition algorithm, and at common recognition
After the completion of reason, the transaction can be executed.
Wherein, in the transaction of user's publication, it can be stated that the assets object for the first Asset Type converted;Example
Such as, in one implementation, in the transaction of user based on the private key publication held, it can be stated that the assets pair converted
The address information of elephant or other types of identification information, and the node device of the transaction is received, the transaction can be based on
The information of middle statement, to determine the assets object converted.
Further, in addition to that can state the assets pair for the first Asset Type converted in the transaction of publication
The second Asset Type as that in addition, can also state this request conversion.
And the node device in block chain is when executing the transaction, can by call publication on block chain with it is upper
It states the corresponding contract object of the second Asset Type and the assets object of above-mentioned first Asset Type is converted into the money of Second Type
Produce object.
In a kind of embodiment shown, the contract pair corresponding with above-mentioned second Asset Type on block chain is issued
As in, other than it can state to create the execution program of assets object in advance, can also in advance it state for Asset Type
Conversion rule between the execution program and above-mentioned first Asset Type and above-mentioned second Asset Type converted.
Wherein, the specific rules content of above-mentioned conversion rule, in the present specification without being particularly limited to;For example, one
In kind embodiment, above-mentioned conversion rule can specifically include the assets object of above-mentioned first Asset Type, and conversion becomes valence
It is worth the assets object of identical second Asset Type.The side for the transaction that i.e. user can be by initiation for converting Asset Type
The assets object of first Asset Type of user's statement is converted into the assets pair for being worth identical second Asset Type by formula
As.
Certainly, in practical applications, can also include that other conversions are advised other than conversion described above rule
Then;For example, by the assets object of above-mentioned first Asset Type, conversion becomes the assets pair of identical second Asset Type of number
As, etc.;It is no longer enumerated in the present specification.
Execution logic corresponding to the above-mentioned execution program for being converted to Asset Type, in the present specification also not
It is particularly limited, it is self-defined that those skilled in the art can be based on the progress of actual demand;For example, in some cases, on
Stating and executing program is stated in advance in Code fields in contract object, for describing above-mentioned conversion rule
Execute code.
In this case, node device is executing assets object progress assets class of the transaction to above-mentioned first Asset Type
When type is converted, the execution program for being converted to Asset Type stated in above-mentioned contract object can be called, being based on should
The above-mentioned conversion rule stated in contract object, by the assets object of the above-mentioned first kind, conversion becomes above-mentioned second assets class
The assets object of type;Then, the execution program for creating assets object stated in above-mentioned contract object, base are further called
In above scaling results, the assets object of second Asset Type is created, by the assets object of above-mentioned first Asset Type
Be converted to the assets object of the second Asset Type.
For example, being that the assets object of above-mentioned first Asset Type is scaled value identical second with above-mentioned conversion rule
For the assets object of Asset Type, when by calling above-mentioned contract object, the assets object of above-mentioned first Asset Type is changed
After calculating to be worth the assets object of identical second Asset Type, can further it call above-mentioned for creating holding for assets object
The assets object of line program, establishment one and above-mentioned first Asset Type is worth the assets object of identical second Asset Type.
It in the present specification, will be upper when node device is by calling corresponding with above-mentioned second Asset Type contract object
State the first Asset Type assets object be converted to the assets object of above-mentioned second Asset Type after, can further by this second
The assets object of Asset Type is added to the target object for the assets object for holding above-mentioned first Asset Type.
Wherein, it should be noted that in the present specification, above-mentioned first Asset Type and above-mentioned second Asset Type can
With the identical contract object of correspondence, different contract objects can also be corresponded to;
Under a kind of scene, above-mentioned first Asset Type and above-mentioned second Asset Type can be under the jurisdiction of same contract object
The two different assets subtypes for including in corresponding Asset Type, in this case, above-mentioned first Asset Type and upper
Identical contract object can be corresponded to by stating the second Asset Type.
If above-mentioned first Asset Type and above-mentioned second Asset Type correspond to identical contract object, by with above-mentioned
The corresponding contract object of two Asset Types can be directed to above-mentioned first Asset Type and carry out relevant management operation;For example, when logical
It crosses and calls corresponding with above-mentioned second Asset Type contract object, the assets object of above-mentioned first Asset Type is converted into the
It, can be by calling contract object corresponding with above-mentioned second Asset Type, to user's original after the assets object of two Asset Types
It modifies and changes come the assets object for the first Asset Type held.
Under another scene, above-mentioned first Asset Type and above-mentioned second Asset Type can correspond to different money respectively
Type is produced, in this case, above-mentioned first Asset Type and above-mentioned second Asset Type can correspond to different contracts respectively
Object.
If above-mentioned first Asset Type and above-mentioned second Asset Type correspond to different contract objects respectively, by with it is upper
The corresponding contract object of the second Asset Type is stated, above-mentioned first Asset Type can not be directed to and carry out relevant management operation;For example,
When by calling corresponding with above-mentioned second Asset Type contract object, the assets object of above-mentioned first Asset Type is converted into
After the assets object of the second Asset Type, it will be unable to by calling contract object corresponding with above-mentioned second Asset Type, it is right
The assets object for the first Asset Type that user held originally is modified and is changed.
In a kind of embodiment shown, for the first scene illustrated above, if above-mentioned first Asset Type
Different contract objects is corresponded to respectively with above-mentioned second Asset Type, due to passing through contract corresponding with above-mentioned second Asset Type
Object can not be managed operation for above-mentioned first Asset Type, therefore user is initiating above-mentioned first will held of merchandising
When the assets object of Asset Type is converted to the assets object of the second Asset Type, it can state to provide above-mentioned first in transaction
" tenure " for producing the assets object of type is transferred to the corresponding publisher of corresponding with above-mentioned second Asset Type contract object.
In this case, node device is completed by calling contract object corresponding with above-mentioned second Asset Type
After the Asset Type conversion of the assets object of above-mentioned first Asset Type, by the assets object of transformed Second Type, add
It, first can be from holding above-mentioned first when adding to the target object for the assets object that above-mentioned user holds above-mentioned first Asset Type
The assets object of above-mentioned first Asset Type is removed in Balance fields in the target object of the assets object of Asset Type
Address information, and by the address information of the assets object of above-mentioned first Asset Type, it is added to publication and above-mentioned second assets class
The assets for the assets object that the target members of the corresponding contract object of type hold above-mentioned first Asset Type hold object, will be above-mentioned
" tenure " of the assets object of first Asset Type is transferred to the publisher for issuing above-mentioned contract object.Then, after reconvert
Above-mentioned second Asset Type assets object address information, be added to the money that above-mentioned user holds above-mentioned first Asset Type
Produce the Balance fields in the target object of object.
In this way so that above-mentioned first Asset Type and the corresponding different contract object of above-mentioned second Asset Type
When, user can be by being transferred to publication and above-mentioned second assets by " tenure " of the assets object of above-mentioned first Asset Type
The mode of the publisher of the corresponding contract object of type, to complete the assets class of the assets object for above-mentioned first Asset Type
Type is converted;For example, by taking the publisher of the corresponding contract object of above-mentioned second Asset Type is financial institution as an example, in such case
Under, it (is not the assets pair of financial institution publication to be equivalent to user by the assets object for above-mentioned first Asset Type held
As) " mortgage " to the financial institution, it is the assets pair that the user re-creates second Asset Type to entrust the financial institution
As to complete the Asset Type conversion for the assets object held.
In a kind of embodiment shown, for second of scene illustrated above, if above-mentioned first Asset Type
Identical contract object is corresponded to above-mentioned second Asset Type, due to passing through contract pair corresponding with above-mentioned second Asset Type
As operation can be managed for above-mentioned first Asset Type, therefore user is in above-mentioned first money that will hold of initiating to merchandise
When the assets object of production type is converted to the assets object of the second Asset Type, it can not state to provide above-mentioned first in transaction
" tenure " for producing the assets object of type is transferred to the corresponding publisher of corresponding with above-mentioned second Asset Type contract object,
But by node device by calling contract object corresponding with above-mentioned second Asset Type, above-mentioned first Asset Type is corresponded to
Assets object modify and update.
In this case, node device is completed by calling contract object corresponding with above-mentioned second Asset Type
After the Asset Type conversion of the assets object of above-mentioned first Asset Type, by the assets object of transformed Second Type, add
When adding to the target object for the assets object that above-mentioned user holds above-mentioned first Asset Type, it will can directly hold above-mentioned first
The address information of the assets object of above-mentioned first Asset Type in the target object of the assets object of Asset Type is revised as turning
The address information of the assets object of above-mentioned second Asset Type after changing.
In this way so that above-mentioned first Asset Type identical contract object corresponding with above-mentioned second Asset Type
When, " tenure " of the assets object of above-mentioned first Asset Type is not simultaneously transferred to publication and above-mentioned second assets class by user
The publisher of the corresponding contract object of type, to complete the Asset Type conversion for the assets object of above-mentioned first Asset Type;
For example, still by taking the publisher of the corresponding contract object of above-mentioned second Asset Type is financial institution as an example, this
In the case of, since above-mentioned first Asset Type and above-mentioned second Asset Type are the assets object of financial institution distribution, because
For the user of this assets object for holding above-mentioned first Asset Type, do not need to above-mentioned first Asset Type
Assets object be transferred to the financial institution, but will directly be held by calling above-mentioned contract object by the financial institution
The address information for stating the assets object of the first Asset Type is revised as transformed above-mentioned second Asset Type.
Wherein, above-mentioned target members hold the assets of the assets object of above-mentioned second Asset Type and hold object, specifically may be used
To include two kinds of situations described below:
In one case, above-mentioned target members hold the assets of the assets object of above-mentioned second Asset Type and hold pair
As that can be specifically the asset acceptance side's object specified by above-mentioned target members.
For example, when realizing, node device adds in the assets object for above-mentioned first Asset Type for needing to hold user
When adding to assets corresponding with above-mentioned target members and holding object, it can be sent to the corresponding access client of above-mentioned target members
Prompting message, to prompt the assets of the specified assets object for holding above-mentioned first Asset Type of the target members to hold object.And
Above-mentioned target members manual-up can state node device and submit specified money after receiving the prompt by access client and disappearing
Object is held in production.
In another case, above-mentioned target members hold the assets of the assets object of above-mentioned second Asset Type and hold pair
As can also be specifically the asset acceptance side pair stated in advance in above-mentioned contract object corresponding with above-mentioned second Asset Type
As.For example, by taking above-mentioned target members are to access the financial institution of alliance's chain as an example, above-mentioned financial institution is issuing the contract object
When, it can state asset acceptance side's object of financial institution's holding assets object in advance in contract object.
Wherein, it should be noted that in the present specification, either hold the assets object of above-mentioned first Asset Type
Target object, or the corresponding assets of publisher of contract object corresponding with above-mentioned second Asset Type hold object, can be with
Any one in account object, contract object and the assets object supported including above-mentioned alliance's chain.I.e. in the present specification,
Any one type that can be by assets object in account object, contract object and the assets object that above-mentioned alliance's chain is supported
Object in held.
Wherein, it should be noted that under some scenes, usually can also state have in advance in above-mentioned contract object
To the user list of the calling permission of the contract object, thus in such a scenario, the node device of block chain is receiving user
After transaction based on private key publication, in the stage for carrying out authentication to the user, can further the certification user whether have
There is the calling permission for the contract object;If by certification, confirm that the user has the calling permission of the contract object, then
The execution program for creating assets object or assets transfer object stated in above-mentioned contract object is called, assets pair are completed
The establishment and transfer of elephant,
For example, that is stated in above-mentioned contract object has the user list to the calling permission of the contract object, specifically
Can be the list of public keys that a user holds, after the node device of block chain receives the transaction that user is issued based on private key,
Authentication can be carried out to the user based on the public key in the list of public keys;If certification passes through, show that the user is that have
The user of the calling permission of the contract object.
Certainly, in practical applications, whether the user of verification submission transaction has the specific of the calling permission of contract object
Mode can also pass through others other than the public key illustrated above held based on user carries out authentication to user
Mode is realized, is in the present specification no longer enumerated.
By above example, in the present specification, user can initiate assets object convert requests, turn in assets object
The assets object for the first Asset Type for stating to be converted, and the second Asset Type of request conversion are changed in request, tune is passed through
With the contract object corresponding with the second Asset Type on block chain is issued, by the assets pair for the first Asset Type converted
As the assets object of the second Asset Type of request conversion being converted to, then by the assets pair of transformed second Asset Type
As being added in the target object for the assets object for holding the first Asset Type, so as to realize money with the real world
Production, the digital asset transformed on block chain are held, and rely on the type conversion of the online completion assets of block chain.
Corresponding with above method embodiment, this specification additionally provides a kind of embodiment of asset management device.This theory
The embodiment of the asset management device of bright book can be applied on an electronic device.Device embodiment can by software realization,
It can be realized by way of hardware or software and hardware combining.For implemented in software, as the device on a logical meaning,
It is that corresponding computer program instructions in nonvolatile memory are read by memory by the processor of electronic equipment where it
What middle operation was formed.For hardware view, as shown in Fig. 2, for electronic equipment where the asset management device of this specification
A kind of hardware structure diagram is implemented other than processor shown in Fig. 2, memory, network interface and nonvolatile memory
Electronic equipment in example where device can also include other hardware, not to this generally according to the actual functional capability of the electronic equipment
It repeats again.
Fig. 3 is a kind of block diagram of asset management device shown in one exemplary embodiment of this specification.
Referring to FIG. 3, the asset management device 30 can be applied in aforementioned electronic equipment shown in Fig. 2, include:
Receiving module 301, conversion module 302 and add module 303.
Receiving module 301 receives assets object convert requests;Wherein, the assets object convert requests include being turned
Second Asset Type of the assets object and request conversion of the first Asset Type changed;
Conversion module 302, in response to the assets object convert requests, call publication on the block chain with it is described
The assets object of first Asset Type is converted to second Asset Type by the corresponding contract object of the second Asset Type
Assets object;
The assets object of transformed second Asset Type is added to and holds first money by add module 303
Produce the target object of the assets object of type.
In the present embodiment, for converting Asset Type first execution program is stated in the contract object, is used for
Create assets object that the second of assets object executes program and first Asset Type and second Asset Type
Conversion rule between assets object;
The conversion module 302:
It calls described in being stated in contract object corresponding with second Asset Type of the publication on the block chain
First executes program, and the assets object of first Asset Type is scaled the second assets class based on conversion rule
The assets object of type;And
It further calls and is stated in contract object corresponding with second Asset Type of the publication on the block chain
It is described second execute program, create the assets object of second Asset Type conversed.
In the present embodiment, the conversion rule includes:
The assets object of first Asset Type is scaled to the assets object for being worth identical second Asset Type.
In the present embodiment, the add module 303:
The money of first Asset Type is removed from the target object of assets object for holding first Asset Type
The address information of the assets object of first Asset Type is added to the publication contract object by the address information for producing object
The assets of target members' assets object for holding second Asset Type hold object;And by the transformed institute
The assets object for stating the second Asset Type is added to the target object.
In the present embodiment, the add module 303:
The assets of first Asset Type in the target object of the assets object of first Asset Type will be held
The address information of object is revised as the address information of the assets object of transformed second Asset Type.
In the present embodiment, the object that the block chain is supported includes address field;Described address field is for maintenance pair
As the address information for the assets object held.
In the present embodiment, the object that the block chain is supported further includes code field;The code field is for safeguarding
The relevant execution code of execution program of object statement.
In the present embodiment, the assets hold object and include:
The assets specified by the target members hold object;Alternatively,
And the assets corresponding with the target members stated in the corresponding contract object of second Asset Type are held
Object.
In the present embodiment, the object that the block chain is supported includes account object, contract object and assets object;
The object of holding assets object includes any in account object, contract object and assets object.
In the present embodiment, the block chain is alliance's chain;Target members in the block chain are in alliance's chain
Allied member with assets Object Creation permission.
The function of modules and the realization process of effect specifically refer to and correspond to step in the above method in above-mentioned apparatus
Realization process, details are not described herein.
For device embodiments, since it corresponds essentially to embodiment of the method, so related place is referring to method reality
Apply the part explanation of example.The apparatus embodiments described above are merely exemplary, wherein described be used as separating component
The module of explanation may or may not be physically separated, and the component shown as module can be or can also
It is not physical module, you can be located at a place, or may be distributed on multiple network modules.It can be according to actual
It needs that some or all of module therein is selected to realize the purpose of this specification scheme.Those of ordinary skill in the art are not
In the case of making the creative labor, you can to understand and implement.
System, device, module or the module that above-described embodiment illustrates can specifically realize by computer chip or entity,
Or it is realized by the product with certain function.A kind of typically to realize that equipment is computer, the concrete form of computer can
To be personal computer, laptop computer, cellular phone, camera phone, smart phone, personal digital assistant, media play
In device, navigation equipment, E-mail receiver/send equipment, game console, tablet computer, wearable device or these equipment
The combination of arbitrary several equipment.
Corresponding with above method embodiment, this specification additionally provides the embodiment of a kind of electronic equipment.The electronics is set
It is standby to include:Processor and memory for storing machine-executable instruction;Wherein, processor and memory are usually by interior
Portion's bus is connected with each other.In other possible realization methods, the equipment is also possible that external interface, with can be with other
Equipment or component are communicated.
In the present embodiment, by reading and executing the corresponding with the control logic of asset management of the memory storage
Machine-executable instruction, the processor are prompted to:
The node device of block chain receives assets object convert requests;Wherein, the assets object convert requests include
Second Asset Type of the assets object and request conversion of the first Asset Type converted;
In response to the assets object convert requests, call publication on the block chain with second Asset Type
The assets object of first Asset Type is converted to the assets object of second Asset Type by corresponding contract object;
The assets object of transformed second Asset Type is added to the assets for holding first Asset Type
The target object of object.
In the present embodiment, for converting Asset Type first execution program is stated in the contract object, is used for
Create assets object that the second of assets object executes program and first Asset Type and second Asset Type
Conversion rule between assets object;
By the executable finger of machine corresponding with the control logic of asset management for reading and executing the memory storage
It enables, the processor is prompted to:
It calls described in being stated in contract object corresponding with second Asset Type of the publication on the block chain
First executes program, and the assets object of first Asset Type is scaled the second assets class based on conversion rule
The assets object of type;And
It further calls and is stated in contract object corresponding with second Asset Type of the publication on the block chain
It is described second execute program, create the assets object of second Asset Type conversed.
In the present embodiment, by reading and executing the corresponding with the control logic of asset management of the memory storage
Machine-executable instruction, the processor are prompted to:
The money of first Asset Type is removed from the target object of assets object for holding first Asset Type
The address information of the assets object of first Asset Type is added to the publication contract object by the address information for producing object
The assets of target members' assets object for holding second Asset Type hold object;And by the transformed institute
The assets object for stating the second Asset Type is added to the target object.
In the present embodiment, by reading and executing the corresponding with the control logic of asset management of the memory storage
Machine-executable instruction, the processor are prompted to:
The assets of first Asset Type in the target object of the assets object of first Asset Type will be held
The address information of object is revised as the address information of the assets object of transformed second Asset Type.
Those skilled in the art after considering the specification and implementing the invention disclosed here, will readily occur to this specification
Other embodiments.This specification is intended to cover any variations, uses, or adaptations of this specification, these modifications,
Purposes or adaptive change follow the general principle of this specification and include that this specification is undocumented in the art
Common knowledge or conventional techniques.The description and examples are only to be considered as illustrative, the true scope of this specification and
Spirit is indicated by the following claims.
It should be understood that this specification is not limited to the precision architecture for being described above and being shown in the accompanying drawings,
And various modifications and changes may be made without departing from the scope thereof.The range of this specification is only limited by the attached claims
System.
The foregoing is merely the preferred embodiments of this specification, all in this explanation not to limit this specification
Within the spirit and principle of book, any modification, equivalent substitution, improvement and etc. done should be included in the model of this specification protection
Within enclosing.