mirror of
https://github.com/corda/corda.git
synced 2025-04-07 11:27:01 +00:00
Minor: yet another small move
This commit is contained in:
parent
bf3aed11e7
commit
8d041a6b1a
@ -13,8 +13,8 @@ import core.crypto.DigitalSignature
|
||||
import core.crypto.SecureHash
|
||||
import core.crypto.signWithECDSA
|
||||
import core.crypto.toStringShort
|
||||
import core.node.TimestampingError
|
||||
import core.node.services.TimestamperService
|
||||
import core.node.services.TimestampingError
|
||||
import core.serialization.SerializedBytes
|
||||
import core.serialization.deserialize
|
||||
import core.serialization.serialize
|
||||
|
@ -1,15 +0,0 @@
|
||||
package core.node
|
||||
|
||||
sealed class TimestampingError : Exception() {
|
||||
class RequiresExactlyOneCommand : TimestampingError()
|
||||
/**
|
||||
* Thrown if an attempt is made to timestamp a transaction using a trusted timestamper, but the time on the
|
||||
* transaction is too far in the past or future relative to the local clock and thus the timestamper would reject
|
||||
* it.
|
||||
*/
|
||||
class NotOnTimeException : TimestampingError()
|
||||
|
||||
/** Thrown if the command in the transaction doesn't list this timestamping authorities public key as a signer */
|
||||
class NotForMe : TimestampingError()
|
||||
}
|
||||
|
@ -37,3 +37,16 @@ object DummyTimestampingAuthority {
|
||||
val key = generateKeyPair()
|
||||
val identity = Party("Mock Company 0", key.public)
|
||||
}
|
||||
|
||||
sealed class TimestampingError : Exception() {
|
||||
class RequiresExactlyOneCommand : TimestampingError()
|
||||
/**
|
||||
* Thrown if an attempt is made to timestamp a transaction using a trusted timestamper, but the time on the
|
||||
* transaction is too far in the past or future relative to the local clock and thus the timestamper would reject
|
||||
* it.
|
||||
*/
|
||||
class NotOnTimeException : TimestampingError()
|
||||
|
||||
/** Thrown if the command in the transaction doesn't list this timestamping authorities public key as a signer */
|
||||
class NotForMe : TimestampingError()
|
||||
}
|
||||
|
@ -17,8 +17,6 @@ import core.messaging.LegallyIdentifiableNode
|
||||
import core.messaging.MessageRecipients
|
||||
import core.messaging.MessagingService
|
||||
import core.messaging.StateMachineManager
|
||||
import core.node.TimestampingError
|
||||
import core.node.services.TimestamperService
|
||||
import core.protocols.ProtocolLogic
|
||||
import core.serialization.SerializedBytes
|
||||
import core.serialization.deserialize
|
||||
|
@ -10,8 +10,8 @@ package contracts
|
||||
|
||||
import core.*
|
||||
import core.crypto.SecureHash
|
||||
import core.node.TimestampingError
|
||||
import core.node.services.DummyTimestampingAuthority
|
||||
import core.node.services.TimestampingError
|
||||
import core.testutils.*
|
||||
import org.junit.Test
|
||||
import org.junit.runner.RunWith
|
||||
|
@ -12,7 +12,6 @@ import core.crypto.*
|
||||
import core.messaging.MessagingService
|
||||
import core.messaging.MockNetworkMap
|
||||
import core.messaging.NetworkMap
|
||||
import core.node.TimestampingError
|
||||
import core.node.services.*
|
||||
import core.serialization.SerializedBytes
|
||||
import core.serialization.deserialize
|
||||
|
@ -12,10 +12,7 @@ import co.paralleluniverse.fibers.Suspendable
|
||||
import core.*
|
||||
import core.crypto.SecureHash
|
||||
import core.messaging.*
|
||||
import core.node.services.ServiceHub
|
||||
import core.node.services.TimestamperNodeService
|
||||
import core.node.services.TimestampingMessages
|
||||
import core.node.services.TimestampingProtocol
|
||||
import core.node.services.*
|
||||
import core.protocols.ProtocolLogic
|
||||
import core.serialization.serialize
|
||||
import core.testutils.ALICE
|
||||
|
Loading…
x
Reference in New Issue
Block a user