import { TryToTransformStringInNumber } from '../../../shared/decorators/class-transformer/try-to-transform-string-in-number.decorator';
import { NutrientPer100GramsDto } from '../../../shared/dtos/nutrients/nutrient-per-100-grams.dto';

export class RetrieveFood_Food {
  id: number;
  name: string;

  @TryToTransformStringInNumber()
  kcalPer100: number | string;

  category: string;
  nutrients: NutrientPer100GramsDto;

  constructor(partial: Partial<RetrieveFood_Food>) {
    Object.assign(this, partial);
  }
}

export class RetrieveFoodResponseDto {
  data: RetrieveFood_Food;
}
