示例#1
0
            ///
            ///		 <summary> * get double attribute Amount, defaults to the value of Amount for the linked partition
            ///		 *  </summary>
            ///		 * <param name="mPart"> partition map to retrieve Amount for </param>
            ///		 * <returns> the amount, -1 if none is specified
            ///		 *
            ///		 * @default getAmount(null) </returns>
            ///
            public static double getAmount(IAmountPoolContainer poolParent, JDFAttributeMap mPart)
            {
                double d = getAmountPoolDouble(poolParent, AttributeName.AMOUNT, mPart);

                if (d == -1)
                {
                    JDFResource target = poolParent.getLinkRoot();
                    if (target != null)
                    {
                        target = target.getPartition(mPart, null);
                        if (target != null)
                        {
                            return(target.getAmount());
                        }
                    }
                }
                else
                {
                    return(d);
                }

                return(-1.0);
            }