
org.hibernate.search.engine.metadata.impl.ContainedInMetadata Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of hibernate-search-engine Show documentation
Show all versions of hibernate-search-engine Show documentation
Core of the Object/Lucene mapper, query engine and index management
/*
* Hibernate Search, full-text search for your domain model
*
* License: GNU Lesser General Public License (LGPL), version 2.1 or later
* See the lgpl.txt file in the root directory or .
*/
package org.hibernate.search.engine.metadata.impl;
import java.util.Set;
import org.hibernate.annotations.common.reflection.XMember;
import org.hibernate.search.util.impl.CollectionHelper;
import org.hibernate.search.util.impl.ReflectionHelper;
/**
* @author Hardy Ferentschik
* @author Yoann Rodiere
*/
public class ContainedInMetadata {
private final XMember containedInMember;
private final Integer maxDepth;
private final String prefix;
private final Set includePaths;
public ContainedInMetadata(XMember containedInMember, Integer maxDepth, String prefix, String[] includePaths) {
this.containedInMember = containedInMember;
ReflectionHelper.setAccessible( this.containedInMember );
this.maxDepth = maxDepth;
this.prefix = prefix;
this.includePaths = CollectionHelper.asImmutableSet( includePaths );
}
public XMember getContainedInMember() {
return containedInMember;
}
public Integer getMaxDepth() {
return maxDepth;
}
public String getPrefix() {
return prefix;
}
public Set getIncludePaths() {
return includePaths;
}
@Override
public String toString() {
final StringBuilder sb = new StringBuilder( "ContainedInMetadata{" );
sb.append( "containedInMember=" ).append( containedInMember );
sb.append( ", maxDepth=" ).append( maxDepth );
sb.append( '}' );
return sb.toString();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy