Files
vm/factory.go
zeekay 3c474ee7b9 feat: consolidate shared VM chain components from node
Add vm/chain package with shared block caching infrastructure:
- BlockWrapper: Smart caching layer for VM blocks
- State: Block cache management (verified, decided, unverified)
- Status: Block status enum (Unknown, Processing, Rejected, Accepted)

Add Factory interface for VM instantiation.

This consolidation allows evm, coreth, and node to import from
github.com/luxfi/vm/chain without creating circular dependencies.

The chain package replaces node/vms/components/chain/ and can now
be imported directly by EVM implementations.
2026-01-01 13:44:08 -08:00

16 lines
365 B
Go

// Copyright (C) 2019-2025, Lux Industries Inc. All rights reserved.
// See the file LICENSE for licensing terms.
package vm
import (
"github.com/luxfi/log"
)
// Factory creates new VM instances.
// A Factory creates new instances of a VM
type Factory interface {
// New creates a new VM instance with the given logger.
New(log.Logger) (interface{}, error)
}