docs(transformer): add documentation for Targets::get_targets (#5337)

`Targets` will be public in follow-up PRs.
This commit is contained in:
Dunqing 2024-08-30 09:30:14 +00:00
parent 3ae94b8801
commit 8334bd4fa2

View file

@ -29,6 +29,13 @@ impl Default for Targets {
}
impl Targets {
/// Parse the query and return the parsed Versions.
///
/// # Errors
///
/// This function returns an error if:
/// * The query is not supported.
/// * The query is invalid.
pub fn get_targets(self) -> Result<Versions, Error> {
match self {
Targets::Versions(v) => Ok(v),