#include <iostream>
#include <string>
#include <vector>
template <int M, int K, int S>
struct MksUnit
{
enum
{
metre = M,
kilogram = K,
second = S
};
};
template <typename MksUnit>
class Value {
private:
long double mag{ 0.0 };
public:
explicit Value(const long double m) : mag(m) {}
long double getValue() const
{
return mag;
}
};
using Monentum = Value<MksUnit<1, 1, -1>>;
using Force = Value<MksUnit<1, 1, -2>>;
class STC
{
public:
void applyMTSB(const Monentum& implusValue)
{
std::cout << implusValue.getValue() << std::endl;
}
};
int main()
{
STC control;
Monentum mom { 13.75 };
control.applyMTSB(mom);
return 0;
}
网友评论