Examples of custom()


Examples of edu.buffalo.cse.ir.wikiindexer.wikipedia.WikipediaParser.custom()

            {

              doc = new WikipediaDocument(id, publishDate,author, title);
              WikipediaParser wp = new WikipediaParser();
              String txt = text.toString(); //converting to string
              doc=wp.custom(doc, txt);   // final calling***********
              add(doc, docs);

              //System.out.println(doc.getSections().get(1).getText());
              //System.out.println(doc.getPublishDate());

View Full Code Here

Examples of org.elasticsearch.cluster.metadata.IndexMetaData.custom()

                for (String index : concreteIndices) {
                    IndexMetaData indexMetaData = currentState.metaData().index(index);
                    if (indexMetaData == null) {
                        throw new IndexMissingException(new Index(index));
                    }
                    IndexWarmersMetaData warmers = indexMetaData.custom(IndexWarmersMetaData.TYPE);
                    if (warmers != null) {
                        List<IndexWarmersMetaData.Entry> entries = Lists.newArrayList();
                        for (IndexWarmersMetaData.Entry entry : warmers.entries()) {
                            boolean keepWarmer = true;
                            for (String warmer : request.names()) {
View Full Code Here

Examples of org.elasticsearch.cluster.metadata.IndexMetaData.custom()

                    for (String index : concreteIndices) {
                        IndexMetaData indexMetaData = currentState.metaData().index(index);
                        if (indexMetaData == null) {
                            throw new IndexMissingException(new Index(index));
                        }
                        IndexWarmersMetaData warmers = indexMetaData.custom(IndexWarmersMetaData.TYPE);
                        if (warmers != null) {
                            for (IndexWarmersMetaData.Entry entry : warmers.entries()) {
                                for (String warmer : request.names()) {
                                    if (Regex.simpleMatch(warmer, entry.name()) || warmer.equals("_all")) {
                                        logger.info("[{}] delete warmer [{}]", index, entry.name());
View Full Code Here

Examples of org.elasticsearch.cluster.metadata.IndexMetaData.custom()

                        for (String index : concreteIndices) {
                            IndexMetaData indexMetaData = metaData.index(index);
                            if (indexMetaData == null) {
                                throw new IndexMissingException(new Index(index));
                            }
                            IndexWarmersMetaData warmers = indexMetaData.custom(IndexWarmersMetaData.TYPE);
                            if (warmers == null) {
                                logger.info("[{}] putting warmer [{}]", index, request.name());
                                warmers = new IndexWarmersMetaData(new IndexWarmersMetaData.Entry(request.name(), request.searchRequest().types(), request.searchRequest().queryCache(), source));
                            } else {
                                boolean found = false;
View Full Code Here

Examples of org.elasticsearch.cluster.metadata.MetaData.custom()

                    // The new repository has the same settings as the old one - ignore
                    return currentState;
                }
                MetaData metaData = currentState.metaData();
                MetaData.Builder mdBuilder = MetaData.builder(currentState.metaData());
                RepositoriesMetaData repositories = metaData.custom(RepositoriesMetaData.TYPE);
                if (repositories == null) {
                    logger.info("put repository [{}]", request.name);
                    repositories = new RepositoriesMetaData(new RepositoryMetaData(request.name, request.type, request.settings));
                } else {
                    boolean found = false;
View Full Code Here

Examples of org.elasticsearch.cluster.metadata.MetaData.custom()

            @Override
            public ClusterState execute(ClusterState currentState) {
                ensureRepositoryNotInUse(currentState, request.name);
                MetaData metaData = currentState.metaData();
                MetaData.Builder mdBuilder = MetaData.builder(currentState.metaData());
                RepositoriesMetaData repositories = metaData.custom(RepositoriesMetaData.TYPE);
                if (repositories != null && repositories.repositories().size() > 0) {
                    List<RepositoryMetaData> repositoriesMetaData = new ArrayList<>(repositories.repositories().size());
                    boolean changed = false;
                    for (RepositoryMetaData repositoryMetaData : repositories.repositories()) {
                        if (Regex.simpleMatch(request.name, repositoryMetaData.name())) {
View Full Code Here

Examples of org.elasticsearch.cluster.metadata.MetaData.custom()

        }

        @Override
        public ClusterState execute(ClusterState currentState) {
            MetaData metaData = currentState.getMetaData();
            BenchmarkMetaData bmd = metaData.custom(BenchmarkMetaData.TYPE);
            MetaData.Builder mdBuilder = MetaData.builder(metaData);
            if (bmd != null && !bmd.entries().isEmpty()) {
                ImmutableList.Builder<BenchmarkMetaData.Entry> builder = new ImmutableList.Builder<BenchmarkMetaData.Entry>();
                for (BenchmarkMetaData.Entry e : bmd.entries()) {
                    if (benchmarkId == null || match(e)) {
View Full Code Here

Examples of org.elasticsearch.cluster.metadata.MetaData.custom()

    }

    @Override
    protected void masterOperation(final GetRepositoriesRequest request, ClusterState state, final ActionListener<GetRepositoriesResponse> listener) throws ElasticsearchException {
        MetaData metaData = state.metaData();
        RepositoriesMetaData repositories = metaData.custom(RepositoriesMetaData.TYPE);
        if (request.repositories().length == 0 || (request.repositories().length == 1 && "_all".equals(request.repositories()[0]))) {
            if (repositories != null) {
                listener.onResponse(new GetRepositoriesResponse(repositories.repositories()));
            } else {
                listener.onResponse(new GetRepositoriesResponse(ImmutableList.<RepositoryMetaData>of()));
View Full Code Here

Examples of org.elasticsearch.cluster.metadata.MetaData.custom()

        }

        @Override
        public ClusterState execute(ClusterState currentState) {
            MetaData metaData = currentState.getMetaData();
            BenchmarkMetaData bmd = metaData.custom(BenchmarkMetaData.TYPE);
            MetaData.Builder mdBuilder = MetaData.builder(metaData);
            ImmutableList.Builder<BenchmarkMetaData.Entry> builder = ImmutableList.builder();

            if (bmd != null) {
                for (BenchmarkMetaData.Entry entry : bmd.entries()) {
View Full Code Here

Examples of org.gdbms.engine.strategies.Strategy.custom()

      throws ExecutionException {
    Strategy strategy = sm.getStrategy(instr);

    DataSource ret;

    ret = strategy.custom(instr);

    return getModedDataSource(ret, NORMAL);
  }

  /**
 
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.