### Question:
AbstractAttribute implements Attribute<X, Y> { public static String stripThisFromMapping(String mapping) { return replaceThisFromMapping(mapping, ""); } @SuppressWarnings("unchecked")  AbstractAttribute(ManagedViewTypeImplementor<X> declaringType, AttributeMapping mapping, MetamodelBuildingContext context, EmbeddableOwner embeddableMapping); static String stripThisFromMapping(String mapping); static String replaceThisFromMapping(String mapping, String root); final void renderSubqueryExpression(String parent, ServiceProvider serviceProvider, StringBuilder sb); final void renderSubqueryExpression(String parent, String subqueryExpression, String subqueryAlias, ServiceProvider serviceProvider, StringBuilder sb); final void renderCorrelationBasis(String parent, ServiceProvider serviceProvider, StringBuilder sb); final void renderCorrelationResult(String parent, ServiceProvider serviceProvider, StringBuilder sb); final void renderMapping(String parent, ServiceProvider serviceProvider, StringBuilder sb); Map<String, Boolean> getCollectionJoinMappings(ManagedType<?> managedType, MetamodelBuildingContext context); boolean hasJoinFetchedCollections(); boolean hasSelectOrSubselectFetchedAttributes(); boolean hasJpaManagedAttributes(); javax.persistence.metamodel.Attribute<?, ?> getUpdateMappableAttribute(); boolean isUpdateMappable(); Class<?> getCorrelated(); String getCorrelationKeyAlias(); String getCorrelationExpression(); Predicate getCorrelationPredicate(); abstract boolean needsDirtyTracker(); abstract boolean hasDirtyStateIndex(); void checkAttribute(ManagedType<?> managedType, MetamodelBuildingContext context); void checkNestedAttribute(List<AbstractAttribute<?, ?>> parents, ManagedType<?> managedType, MetamodelBuildingContext context, boolean hasMultisetParent); abstract String getLocation(); abstract boolean isUpdatable(); abstract boolean isMutable(); abstract String getMappedBy(); abstract boolean isUpdateCascaded(); abstract Set<Type<?>> getUpdateCascadeAllowedSubtypes(); abstract Type<?> getElementType(); Expression getKeyMappingExpression(); Expression getMappingIndexExpression(); abstract Set<Class<?>> getAllowedSubtypes(); abstract Set<Class<?>> getParentRequiringUpdateSubtypes(); abstract Set<Class<?>> getParentRequiringCreateSubtypes(); abstract boolean isOptimizeCollectionActionsEnabled(); abstract ContainerAccumulator<?> getContainerAccumulator(); abstract CollectionInstantiatorImplementor<?, ?> getCollectionInstantiator(); abstract MapInstantiatorImplementor<?, ?> getMapInstantiator(); @Override final MappingType getMappingType(); final boolean isQueryParameter(); final boolean isId(); final SubqueryProviderFactory getSubqueryProviderFactory(); final Class<? extends SubqueryProvider> getSubqueryProvider(); final String getSubqueryExpression(); final String getSubqueryAlias(); CorrelationProviderFactory getCorrelationProviderFactory(); final Class<? extends CorrelationProvider> getCorrelationProvider(); final String getCorrelationBasis(); final String getCorrelationResult(); Expression getCorrelationBasisExpression(); Expression getCorrelationResultExpression(); final FetchStrategy getFetchStrategy(); final int getBatchSize(); final List<OrderByItem> getOrderByItems(); final String getLimitExpression(); final String getOffsetExpression(); final String getMapping(); @Override final boolean isSubquery(); @Override final ManagedViewTypeImplementor<X> getDeclaringType(); @Override final Class<Y> getJavaType(); @Override Class<?> getConvertedJavaType(); @Override final String[] getFetches();  }### Answer:
@Test public void stripThisFromMappingTests() { assertEquals("", AbstractAttribute.stripThisFromMapping("this")); assertEquals("this[]", AbstractAttribute.stripThisFromMapping("this[]")); assertEquals("this()", AbstractAttribute.stripThisFromMapping("this()")); assertEquals("this", AbstractAttribute.stripThisFromMapping("this.this")); assertEquals("this.this", AbstractAttribute.stripThisFromMapping("this.this.this")); assertEquals("", AbstractAttribute.stripThisFromMapping(" this")); assertEquals("thisa", AbstractAttribute.stripThisFromMapping("thisa")); assertEquals("this MEMBER OF abc", AbstractAttribute.stripThisFromMapping("this MEMBER OF abc")); assertEquals("CASE WHEN this = owner THEN true ELSE false END", AbstractAttribute.stripThisFromMapping("CASE WHEN this = owner THEN true ELSE false END")); assertEquals("TYPE(this)", AbstractAttribute.stripThisFromMapping("TYPE(this)")); assertEquals("TREAT(this AS Subtype)", AbstractAttribute.stripThisFromMapping("TREAT(this AS Subtype)")); }