// Package entstore provides a concrete persistence implementation
// for storing and retrieving AStRA graphs using an Ent-backed database.
//
// This package acts as an adapter between the in-memory graph model
// (graph.AstraGraph) and the underlying database schema generated by Ent.
package entstore

import genent "github.com/TSELab/astra/internal/store/ent"

// Store encapsulates an Ent client and implements persistence
// operations for AStRA graphs.
//
// It is responsible for translating between the graph layer and
// database representations.
type Store struct {
	client *genent.Client
}

// New constructs a new Store using the provided Ent client.
func New(client *genent.Client) *Store {
	return &Store{client: client}
}

// Close releases database resources associated with the store.
func (s *Store) Close() error {
	return s.client.Close()
}
