use get::Get; use std::path::PathBuf; use crate::{ atom::{Atom, Name, Slot, Version}, useflag::{IUseFlag, UseFlag}, }; pub mod parsers; #[derive(Clone, Debug)] pub enum Conditional { Negative(UseFlag), Positive(UseFlag), } #[derive(Clone, Debug)] pub enum Depend { Element(T), AllOf(Vec), AnyOf(Vec), OneOf(Vec), ConditionalGroup(Conditional, Vec), } #[derive(Debug, Clone, Get)] pub struct SrcUri { uri: String, file_name: Option, } #[derive(Debug, Clone, Get)] pub struct License(#[get(method = "get", kind = "deref")] String); #[derive(Debug, Clone, Get)] pub struct Eapi(#[get(method = "get", kind = "deref")] String); #[derive(Debug, Clone, Get)] pub struct Eclass(#[get(method = "get", kind = "deref")] String); #[derive(Debug, Clone, Get)] pub struct Ebuild { name: Name, version: Version, slot: Option, homepage: Option, src_uri: Vec>, eapi: Option, inherit: Vec, iuse: Vec, license: Vec>, description: Option, depend: Vec>, bdepend: Vec>, rdpened: Vec>, idepend: Vec>, }