OSDN Git Service

edht tx txoutput (#1966)
[bytom/bytom.git] / protocol / bc / output.go
index 0c98fa7..74457b9 100644 (file)
@@ -2,22 +2,20 @@ package bc
 
 import "io"
 
-// Output is the result of a transfer of value. The value it contains
+// OriginalOutput is the result of a transfer of value. The value it contains
 // may be accessed by a later Spend entry (if that entry can satisfy
-// the Output's ControlProgram). Output satisfies the Entry interface.
-//
-// (Not to be confused with the deprecated type TxOutput.)
+// the Output's ControlProgram). OriginalOutput satisfies the Entry interface.
 
-func (Output) typ() string { return "output1" }
-func (o *Output) writeForHash(w io.Writer) {
+func (OriginalOutput) typ() string { return "originalOutput1" }
+func (o *OriginalOutput) writeForHash(w io.Writer) {
        mustWriteForHash(w, o.Source)
        mustWriteForHash(w, o.ControlProgram)
        mustWriteForHash(w, o.StateData)
 }
 
-// NewOutput creates a new Output.
-func NewOutput(source *ValueSource, controlProgram *Program, stateData [][]byte, ordinal uint64) *Output {
-       return &Output{
+// NewOriginalOutput creates a new OriginalOutput.
+func NewOriginalOutput(source *ValueSource, controlProgram *Program, stateData [][]byte, ordinal uint64) *OriginalOutput {
+       return &OriginalOutput{
                Source:         source,
                ControlProgram: controlProgram,
                Ordinal:        ordinal,