Заменил SetMaxCount на MaxCount
This commit is contained in:
parent
572648c859
commit
3d5e3f3cdc
@ -48,7 +48,7 @@ namespace ProjectLiner.CollectionGenericObjects
|
||||
_pictureWidth = picWidth;
|
||||
_pictureHeight = picHeight;
|
||||
_collection = collection;
|
||||
_collection.SetMaxCount = GetMaxCount;
|
||||
_collection.MaxCount = GetMaxCount;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -16,7 +16,21 @@ public class ListGenericObjects<T> : ICollectionGenericObjects<T>
|
||||
/// </summary>
|
||||
private int _maxCount;
|
||||
public int Count => _collection.Keys.Count;
|
||||
public int MaxCount { set { if (value > 0) { _maxCount = value; } } }
|
||||
public int MaxCount
|
||||
{
|
||||
get
|
||||
{
|
||||
return _maxCount;
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
if (value > 0)
|
||||
{
|
||||
_maxCount = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public CollectionType GetCollectionType => CollectionType.List;
|
||||
|
||||
|
@ -17,6 +17,11 @@ namespace ProjectLiner.CollectionGenericObjects
|
||||
|
||||
public int MaxCount
|
||||
{
|
||||
get
|
||||
{
|
||||
return _collection.Length;
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
if (value > 0)
|
||||
|
Loading…
Reference in New Issue
Block a user