Indicators of the risk mechanics for Class-I and Class-II amalgam and composite resin restorations