コード例 #1
0
        public static bool IsDaughterOf(GameEntity parent, GameEntity daughter)
        {
            if (!parent.hasShareholder)
            {
                Companies.Log(daughter, $"FALSELY CALLED IS_DAUGHTER_OF on companies: possible parent={parent.company.Name}, possible daughter={daughter.company.Name}");
                return(false);
            }

            return(Investments.IsInvestsInCompany(parent, daughter)); // IsInvestsInCompany(daughter, parent.shareholder.Id);
        }
コード例 #2
0
 public static bool IsInvestsInCompany(GameEntity company, GameEntity investor) => Investments.IsInvestsInCompany(investor, company);
コード例 #3
0
ファイル: SharesQueries.cs プロジェクト: dqchess/Corporations
 public static bool IsInvestsInCompany(GameEntity company, int investorId)
 {
     return(Investments.IsInvestsInCompany(investorId, company));
     //return company.shareholders.Shareholders.ContainsKey(investorId);
 }