From 24555e24ef6ba380dc098d51d11dbc5fd8d0243d Mon Sep 17 00:00:00 2001 From: Shargon Date: Sun, 25 Feb 2024 11:24:25 -0800 Subject: [PATCH] Delete src/Neo.SmartContract.Template/templates/neocontract/Contract1.cs this was removed from templates --- .../templates/neocontract/Contract1.cs | 64 ------------------- 1 file changed, 64 deletions(-) delete mode 100644 src/Neo.SmartContract.Template/templates/neocontract/Contract1.cs diff --git a/src/Neo.SmartContract.Template/templates/neocontract/Contract1.cs b/src/Neo.SmartContract.Template/templates/neocontract/Contract1.cs deleted file mode 100644 index 758b6ae08..000000000 --- a/src/Neo.SmartContract.Template/templates/neocontract/Contract1.cs +++ /dev/null @@ -1,64 +0,0 @@ -using Neo; -using Neo.SmartContract; -using Neo.SmartContract.Framework; -using Neo.SmartContract.Framework.Attributes; -using Neo.SmartContract.Framework.Native; -using Neo.SmartContract.Framework.Services; - -using System; -using System.ComponentModel; - -namespace ProjectName -{ - [DisplayName(nameof(Contract1))] - [ManifestExtra("Author", "")] - [ContractDescription( "")] - [ManifestExtra("Email", "")] - [ManifestExtra("Version", "")] - [ContractSourceCode("https://github.com/neo-project/neo-devpack-dotnet/tree/master/src/Neo.SmartContract.Template")] - [ContractPermission(Permission.WildCard, Method.WildCard)] - public class Contract1 : SmartContract - { - // TODO: Replace it with your own address. - [Hash160("")] - static readonly UInt160 Owner = default; - - private static bool IsOwner() => Runtime.CheckWitness(Owner); - - // When this contract address is included in the transaction signature, - // this method will be triggered as a VerificationTrigger to verify that the signature is correct. - // For example, this method needs to be called when withdrawing token from the contract. - [Safe] - public static bool Verify() => IsOwner(); - - // TODO: Replace it with your methods. - public static string MyMethod() - { - return Storage.Get(Storage.CurrentContext, "Hello"); - } - - public static void _deploy(object data, bool update) - { - if (update) - { - // This will be executed during update - return; - } - - // This will be executed during deploy - Storage.Put(Storage.CurrentContext, "Hello", "World"); - } - - public static void Update(ByteString nefFile, string manifest) - { - if (!IsOwner()) throw new Exception("No authorization."); - ContractManagement.Update(nefFile, manifest, null); - } - - public static void Destroy() - { - if (!IsOwner()) throw new Exception("No authorization."); - ContractManagement.Destroy(); - } - } -}