Package org.apache.metamodel.data

Examples of org.apache.metamodel.data.Document


        }

        final Row row = _rowIterator.next();
        final JsonNode docNode = row.getDocAsNode();
        final Map<String, Object> map = CouchDbUtils.jsonNodeToMap(docNode);
        return new Document(_databaseName, map, row);
    }
View Full Code Here


    @Override
    public void offerSources(DocumentSourceProvider documentSourceProvider) {
        final DocumentSource documentSource = documentSourceProvider.getMixedDocumentSourceForSampling();
        try {
            while (true) {
                final Document document = documentSource.next();
                if (document == null) {
                    break;
                }
                final String tableName = determineTable(document);
                addObservation(tableName, document);
View Full Code Here

    }

    protected void offerDocumentSource(DocumentSource documentSource) {
        try {
            while (true) {
                final Document document = documentSource.next();
                if (document == null) {
                    break;
                }
                final String tableName = determineTable(document);
                addObservation(tableName, document);
View Full Code Here

                databaseName = _databaseNameIterator.next();
            }
            _currentSource = new CouchDbDatabaseDocumentSource(_couchDbInstance, databaseName, 500);
        }

        final Document next = _currentSource.next();
        if (next == null) {
            if (_currentSource != null) {
                _currentSource.close();
            }
            _currentSource = null;
View Full Code Here

                return null;
            }

            if (token == JsonToken.START_OBJECT) {
                Map<String, ?> value = readValue();
                return new Document(_sourceCollectionName, value, value);
            }
        }
    }
View Full Code Here

    }

    @Override
    public void offerSource(DocumentSource documentSource) {
        while (getObservationCount() < MAX_SAMPLE_SIZE) {
            Document map = documentSource.next();
            if (map == null) {
                return;
            }
            addObservation(map);
        }
View Full Code Here

TOP

Related Classes of org.apache.metamodel.data.Document

Copyright © 2018 www.massapicom. 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.