import { SimpleLocalIntegration } from '../../core/index.js';
import { TomatoConfigFlow } from './tomato.classes.configflow.js';
import { createTomatoDiscoveryDescriptor } from './tomato.discovery.js';
import type { ITomatoConfig } from './tomato.types.js';
import { tomatoDomain, tomatoProfile } from './tomato.types.js';

export class TomatoIntegration extends SimpleLocalIntegration<ITomatoConfig> {
  public readonly domain = tomatoDomain;
  public readonly discoveryDescriptor = createTomatoDiscoveryDescriptor();
  public readonly configFlow = new TomatoConfigFlow();

  constructor() {
    super(tomatoProfile);
  }
}

export class HomeAssistantTomatoIntegration extends TomatoIntegration {}
