mirror of
https://github.com/Laupetin/OpenAssetTools.git
synced 2025-06-09 22:38:06 -05:00
ZoneCodeGenerator: Add Computations class for StructureInformation including IsUsed to check whether a structure has at least 1 usage
This commit is contained in:
@ -0,0 +1,20 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using ZoneCodeGenerator.Domain;
|
||||
using ZoneCodeGenerator.Domain.Evaluation;
|
||||
using ZoneCodeGenerator.Domain.Information;
|
||||
|
||||
namespace ZoneCodeGenerator.Generating.Computations
|
||||
{
|
||||
class StructureComputations
|
||||
{
|
||||
private readonly StructureInformation information;
|
||||
|
||||
public bool IsUsed => information.Usages.Any();
|
||||
|
||||
public StructureComputations(StructureInformation information)
|
||||
{
|
||||
this.information = information;
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user