bool AssetMediaInfo::IsAssetMediaInfoSameGuid(
	AssetMediaInfoPtr const& inLeftMediaInfo,
	AssetMediaInfoPtr const& inRightMediaInfo)
{
	ASL_ASSERT(inLeftMediaInfo != NULL && inRightMediaInfo != NULL);
	return inLeftMediaInfo->GetAssetMediaInfoGUID() == inRightMediaInfo->GetAssetMediaInfoGUID();
}
Example #2
0
 void value::set_uint(unsigned int value)
 {
     ASL_ASSERT(is_uint());
     m_uint = value;
 }
Example #3
0
 unsigned int value::get_uint() const
 {
     ASL_ASSERT(is_uint());
     return (m_uint);
 }
Example #4
0
 void value::set_bool(bool value)
 {
     ASL_ASSERT(is_bool());
     m_bool = value;
 }
Example #5
0
    value::ptr_type value::binary_operator(const value& rhs, binary_op op) const
    {
        ASL_ASSERT(get_type() == rhs.get_type());

#define TEST_OP(in_type, out_type, symbol)                                                                                              \
        if (is_##in_type() == true)                                                                                                     \
        {                                                                                                                               \
            value::ptr_type result = get_type().get_type_manager().create_value_##out_type(get_##in_type() symbol rhs.get_##in_type()); \
            return (result);                                                                                                            \
        }

        switch (op)
        {
        case OP_EQUAL:
            {
                TEST_OP(bool, bool, ==)
                TEST_OP(uint, bool, ==)
                break;
            }
        case OP_NOT_EQUAL:
            {
                TEST_OP(bool, bool, !=)
                TEST_OP(uint, bool, !=)
                break;
            }
        case OP_GREATER:
            {
                TEST_OP(uint, bool, >)
                break;
            }
        case OP_GREATER_EQUAL:
            {
                TEST_OP(uint, bool, >=)
                break;
            }
        case OP_LESSER:
            {
                TEST_OP(uint, bool, <)
                break;
            }
        case OP_LESSER_EQUAL:
            {
                TEST_OP(uint, bool, <=)
                break;
            }
        case OP_ADD:
            {
                TEST_OP(uint, uint, +)
                break;
            }
        case OP_SUB:
            {
                TEST_OP(uint, uint, -)
                break;
            }
        case OP_MUL:
            {
                TEST_OP(uint, uint, *)
                break;
            }
        case OP_DIV:
            {
                TEST_OP(uint, uint, /)
                break;
            }
        }
#undef TEST_OP

        ASL_ASSERT(false);
        return (NULL);
    }