/**
 * # System Undelete
 * A system transaction to "undo" a `systemDelete` transaction.<br/>
 * This transaction is a privileged operation restricted to "system"
 * accounts.
 *
 * > Note
 * >> System undelete is defined here for a smart contract (to delete
 * >> the bytecode), but was never implemented.
 * >
 * >> Currently, system delete and system undelete specifying a smart
 * >> contract identifier SHALL return `INVALID_FILE_ID`
 * >> or `MISSING_ENTITY_ID`.
 *
 * ### Keywords
 * The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
 * "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
 * document are to be interpreted as described in
 * [RFC2119](https://www.ietf.org/rfc/rfc2119) and clarified in
 * [RFC8174](https://www.ietf.org/rfc/rfc8174).
 */
syntax = "proto3";

package proto;

// SPDX-License-Identifier: Apache-2.0
option java_package = "com.hederahashgraph.api.proto.java";
// <<<pbj.java_package = "com.hedera.hapi.node.file">>> This comment is special code for setting PBJ Compiler java package
option java_multiple_files = true;

import "services_basic_types.proto";

/**
 * Recover a file or contract bytecode deleted from the Hedera File
 * System (HFS) by a `systemDelete` transaction.
 *
 * > Note
 * >> A system delete/undelete for a `contractID` is not supported and
 * >> SHALL return `INVALID_FILE_ID` or `MISSING_ENTITY_ID`.
 *
 * This transaction can _only_ recover a file removed with the `systemDelete`
 * transaction. A file deleted via `fileDelete` SHALL be irrecoverable.<br/>
 * This transaction MUST be signed by an Hedera administrative ("system")
 * account.
 *
 * ### What is a "system" file
 * A "system" file is any file with a file number less than or equal to the
 * current configuration value for `ledger.numReservedSystemEntities`,
 * typically `750`.
 *
 * ### Block Stream Effects
 * None
 */
message SystemUndeleteTransactionBody {
    oneof id {
        /**
         * A file identifier.
         * <p>
         * The identified file MUST exist in the HFS.<br/>
         * The identified file MUST be deleted.<br/>
         * The identified file deletion MUST be a result of a
         * `systemDelete` transaction.<br/>
         * The identified file MUST NOT be a "system" file.<br/>
         * This field is REQUIRED.
         */
        FileID fileID = 1;

        /**
         * A contract identifier.
         * <p>
         * The identified contract MUST exist in network state.<br/>
         * The identified contract bytecode MUST be deleted.<br/>
         * The identified contract deletion MUST be a result of a
         * `systemDelete` transaction.
         * <p>
         * This option is _unsupported_.
         */
        ContractID contractID = 2;
    }
}
