// Copyright (c) Six Labors.
// Licensed under the Six Labors Split License.
using System;
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using System.Globalization;
namespace SixLabors.Fonts {
///
/// Represents a readonly collection of font metrics.
/// The interface uses compiler pattern matching to provide enumeration capabilities.
///
internal interface IReadOnlyFontMetricsCollection
{
///
/// Gets the specified font metrics matching the given culture and font family name.
///
/// The font family name.
/// The culture to use when searching for a match.
/// The font style to use when searching for a match.
///
/// When this method returns, contains the metrics associated with the specified name,
/// if the name is found; otherwise, the default value for the type of the family parameter.
/// This parameter is passed uninitialized.
///
///
/// if the contains font metrics
/// with the specified name; otherwise, .
///
/// is
public bool TryGetMetrics(string name, CultureInfo culture, FontStyle style, [NotNullWhen(true)] out FontMetrics? metrics);
///
/// Gets the collection of available font metrics for a given culture and font family name.
///
/// The font family name.
/// The culture to use when searching for a match.
/// The .
/// is
public IEnumerable GetAllMetrics(string name, CultureInfo culture);
///
/// Gets the collection of available font styles for a given culture and font family name.
///
/// The font family name.
/// The culture to use when searching for a match.
/// A read-only memory region containing the available font styles.
/// is
public ReadOnlyMemory GetAllStyles(string name, CultureInfo culture);
///
public IEnumerator GetEnumerator();
}
}