작업 조건 분석 기능 개발
This commit is contained in:
38
Assets/Chart And Graph/Script/Common/ChartItemIndex.cs
Normal file
38
Assets/Chart And Graph/Script/Common/ChartItemIndex.cs
Normal file
@@ -0,0 +1,38 @@
|
||||
#define Graph_And_Chart_PRO
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace ChartAndGraph.Common
|
||||
{
|
||||
/// <summary>
|
||||
/// and index of a chart item. this include group and category data.
|
||||
/// </summary>
|
||||
struct ChartItemIndex
|
||||
{
|
||||
public ChartItemIndex(int group,int category) : this()
|
||||
{
|
||||
Group = group;
|
||||
Category = category;
|
||||
}
|
||||
|
||||
public override bool Equals(object obj)
|
||||
{
|
||||
if (obj is ChartItemIndex)
|
||||
{
|
||||
ChartItemIndex index = (ChartItemIndex)obj;
|
||||
if (index.Group == Group && index.Category == Category)
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
public override int GetHashCode()
|
||||
{
|
||||
return Group.GetHashCode() ^ Category.GetHashCode();
|
||||
}
|
||||
public int Group { get; set; }
|
||||
public int Category { get; set; }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user