//NOTE: keeping the pointer in this class only so it can be properly disposed internal SwTempBody(IBody2 body) : base(null, null) { if (!body.IsTemporaryBody()) { throw new ArgumentException("Body is not temp"); } m_TempBody = body; }
//NOTE: keeping the pointer in this class only so it can be properly disposed internal SwTempBody(IBody2 body, ISwApplication app) : base(null, null, app) { if (!body.IsTemporaryBody()) { throw new ArgumentException("Body is not temp"); } m_TempBody = body; m_MathUtils = app.Sw.IGetMathUtility(); }
private IBody2 ConvertToTempIfNeeded(IBody2 body) { if (body.IsTemporaryBody()) { return(body); } else { return(body.ICopy()); } }