PHP WebShell

Текущая директория: /usr/lib/node_modules/bitgo/node_modules/@hashgraph/proto/src/proto/services

Просмотр файла: contract_update.proto

syntax = "proto3";

package proto;

/*-
 * ‌
 * Hedera Network Services Protobuf
 * ​
 * Copyright (C) 2018 - 2021 Hedera Hashgraph, LLC
 * ​
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 * ‍
 */

option java_package = "com.hederahashgraph.api.proto.java";
// <<<pbj.java_package = "com.hedera.hapi.node.contract">>> This comment is special code for setting PBJ Compiler java package
option java_multiple_files = true;

import "basic_types.proto";
import "duration.proto";
import "timestamp.proto";
import "google/protobuf/wrappers.proto";

/**
 * At consensus, updates the fields of a smart contract to the given values.
 * 
 * If no value is given for a field, that field is left unchanged on the contract. For an immutable
 * smart contract (that is, a contract created without an adminKey), only the expirationTime may be
 * updated; setting any other field in this case will cause the transaction status to resolve to
 * MODIFYING_IMMUTABLE_CONTRACT.
 * 
 * --- Signing Requirements ---
 * 1. Whether or not a contract has an admin key, its expiry can be extended with only the
 *    transaction payer's signature.
 * 2. Updating any other field of a mutable contract requires the admin key's signature.
 * 3. If the update transaction includes a new admin key, this new key must also sign <b>unless</b>
 *    it is exactly an empty <tt>KeyList</tt>. This special sentinel key removes the existing admin
 *    key and causes the contract to become immutable. (Other <tt>Key</tt> structures without a
 *    constituent <tt>Ed25519</tt> key will be rejected with <tt>INVALID_ADMIN_KEY</tt>.)
 * 4. If the update transaction sets the AccountID auto_renew_account_id wrapper field to anything
 *    other than the sentinel <tt>0.0.0</tt> value, then the key of the referenced account must sign.
 */
message ContractUpdateTransactionBody {
    /**
     * The id of the contract to be updated
     */
    ContractID contractID = 1;

    /**
     * The new expiry of the contract, no earlier than the current expiry (resolves to
     * EXPIRATION_REDUCTION_NOT_ALLOWED otherwise)
     */
    Timestamp expirationTime = 2;

    /**
     * The new key to control updates to the contract
     */
    Key adminKey = 3;

    /**
     * [Deprecated] The new id of the account to which the contract is proxy staked
     */
    AccountID proxyAccountID = 6 [deprecated = true];

    /**
     * If an auto-renew account is in use, the lifetime to be added by each auto-renewal.
     */
    Duration autoRenewPeriod = 7;

    /**
     * This field is unused and will have no impact on the specified smart contract.
     */
    FileID fileID = 8 [deprecated = true];

    /**
     * The new contract memo, assumed to be Unicode encoded with UTF-8 (at most 100 bytes)
     */
    oneof memoField {
      /**
       * [Deprecated] If set with a non-zero length, the new memo to be associated with the account
       * (UTF-8 encoding max 100 bytes)
       */
      string memo = 9 [deprecated = true];

      /**
       * If set, the new memo to be associated with the account (UTF-8 encoding max 100 bytes)
       */
      google.protobuf.StringValue memoWrapper = 10;
    }

    /**
     * If set, the new maximum number of tokens that this contract can be 
     * automatically associated with (i.e., receive air-drops from).
     */
    google.protobuf.Int32Value max_automatic_token_associations = 11;

    /**
     * If set to the sentinel <tt>0.0.0</tt> AccountID, this field removes the contract's auto-renew 
     * account. Otherwise it updates the contract's auto-renew account to the referenced account.
     */
    AccountID auto_renew_account_id = 12;

    /**
     * ID of the new account or node to which this contract is staking.
     */
    oneof staked_id {

        /**
         * ID of the new account to which this contract is staking. If set to the sentinel <tt>0.0.0</tt> AccountID,
         * this field removes the contract's staked account ID.
         */
        AccountID staked_account_id = 13;

        /**
         * ID of the new node this contract is staked to. If set to the sentinel <tt>-1</tt>, this field
         * removes the contract's staked node ID.
         */
        int64 staked_node_id = 14;
    }

    /**
     * If true, the contract declines receiving a staking reward.
     */
    google.protobuf.BoolValue decline_reward = 15;
}

Выполнить команду


Для локальной разработки. Не используйте в интернете!