[][src]Struct fapt::system::System

pub struct System { /* fields omitted */ }

The core object, tying together configuration, caching, and listing.

Methods

impl System[src]

pub fn cache_only() -> Result<Self, Error>[src]

Produce a System with no configuration, using the user's cache directory.

pub fn cache_only_in<P: AsRef<Path>>(lists_dir: P) -> Result<Self, Error>[src]

Produce a System with no configuration, using a specified cache directory.

pub fn add_sources_entries<I: IntoIterator<Item = Entry>>(&mut self, entries: I)[src]

Add prepared sources entries.

These can be acquired from crate::sources_list. It is not recommended that you build them by hand.

pub fn set_arches<S: ToString, I: IntoIterator<Item = S>>(&mut self, arches: I)[src]

Configure the architectures this system is using.

The first architecture is the "primary" architecture.

pub fn set_dpkg_database<P: AsRef<Path>>(&mut self, dpkg: P)[src]

Configure the location of the dpkg database.

This can be used to view status information, i.e. information on currently installed packages.

pub fn add_keys_from<R: Read>(&mut self, source: R) -> Result<(), Error>[src]

Load GPG keys from an old-style keyring (i.e. not a keybox file).

Note that this will reject invalid keyring files, unlike other *apt implementations.

pub fn update(&self) -> Result<(), Error>[src]

Download any necessary Listings for the configured Sources Entries.

pub fn listings(&self) -> Result<Vec<DownloadedList>, Error>[src]

Explain the configured Listings.

pub fn open_listing(
    &self,
    list: &DownloadedList
) -> Result<ListingBlocks, Error>
[src]

Open a DownloadedList, to access the packages inside it.

pub fn open_status(&self) -> Result<ListingBlocks, Error>[src]

Open the dpkg status database, to access the packages inside it.

Auto Trait Implementations

impl Send for System

impl Sync for System

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Same for T

type Output = T

Should always be Self

impl<T> Erased for T