mirror of
https://github.com/claunia/SabreTools.git
synced 2025-12-16 19:14:27 +00:00
Add transformative get-only accessors for IDDB
This commit is contained in:
@@ -306,10 +306,14 @@ namespace SabreTools.DatFiles
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Get all items from the current dictionary
|
/// Get all item mappings
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public DatItem[] GetItems()
|
public (long, long)[] GetItemMappings() => _itemToMachineMapping.Select(kvp => (kvp.Key, kvp.Value)).ToArray();
|
||||||
=> _items.Select(kvp => kvp.Value).ToArray();
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get all items and their indicies
|
||||||
|
/// </summary>
|
||||||
|
public (long, DatItem)[] GetItems() => _items.Select(kvp => (kvp.Key, kvp.Value)).ToArray();
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Get the indices and items associated with a bucket name
|
/// Get the indices and items associated with a bucket name
|
||||||
@@ -390,10 +394,9 @@ namespace SabreTools.DatFiles
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Get all machines from the current dictionary
|
/// Get all machines and their indicies
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public Machine[] GetMachines()
|
public (long, Machine)[] GetMachines() => _machines.Select(kvp => (kvp.Key, kvp.Value)).ToArray();
|
||||||
=> _machines.Select(kvp => kvp.Value).ToArray();
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Remove an item, returning if it could be removed
|
/// Remove an item, returning if it could be removed
|
||||||
|
|||||||
Reference in New Issue
Block a user