id
stringlengths
7
14
test_class
dict
test_case
dict
focal_class
dict
focal_method
dict
repository
dict
18830102_83
{ "fields": [ { "declarator": "objJPAEdmMappingModelServiceTest", "modifier": "private static", "original_string": "private static JPAEdmMappingModelServiceTest objJPAEdmMappingModelServiceTest;", "type": "JPAEdmMappingModelServiceTest", "var_name": "objJPAEdmMappingModelServiceTest"...
{ "body": "@Test\n public void testMapJPAEntitySet() {\n assertEquals(ENTITY_SET_NAME_EDM, objJPAEdmMappingModelServiceTest.mapJPAEntitySet(ENTITY_TYPE_NAME_JPA));\n }", "class_method_signature": "JPAEdmMappingModelServiceTest.testMapJPAEntitySet()", "constructor": false, "full_signature": "@Test public vo...
{ "fields": [ { "declarator": "mappingModelExists = true", "modifier": "", "original_string": "boolean mappingModelExists = true;", "type": "boolean", "var_name": "mappingModelExists" }, { "declarator": "mappingModel", "modifier": "private", "original_string...
{ "body": "@Override\n public String mapJPAEntitySet(final String jpaEntityTypeName) {\n JPAEntityTypeMapType jpaEntityTypeMap = searchJPAEntityTypeMapType(jpaEntityTypeName);\n if (jpaEntityTypeMap != null) {\n return jpaEntityTypeMap.getEDMEntitySet();\n } else {\n return null;\n }\n }", "...
{ "created": null, "fork": null, "fork_count": 68, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 18830102, "size": 6647, "stargazer_count": 30, "stars": null, "updates": null, "url": "https://github.com/apache/olingo-odata2" }
18830102_869
{ "fields": [ { "declarator": "LOG = Logger.getLogger(XmlEntityConsumerTest.class.getName())", "modifier": "private static final", "original_string": "private static final Logger LOG = Logger.getLogger(XmlEntityConsumerTest.class.getName());", "type": "Logger", "var_name": "LOG" ...
{ "body": "@Test(expected = EntityProviderException.class)\n public void readStringPropertyValueWithInvalidMapping() throws Exception {\n String xml = \"<EmployeeName xmlns=\\\"\" + Edm.NAMESPACE_D_2007_08 + \"\\\">Max Mustermann</EmployeeName>\";\n InputStream content = createContentAsStream(xml);\n final ...
{ "fields": [], "file": "odata2-lib/odata-core/src/main/java/org/apache/olingo/odata2/core/ep/consumer/XmlEntityConsumer.java", "identifier": "XmlEntityConsumer", "interfaces": "", "methods": [ { "class_method_signature": "XmlEntityConsumer.XmlEntityConsumer()", "constructor": true, "ful...
{ "body": "public Object readPropertyValue(final EdmProperty edmProperty, final InputStream content)\n throws EntityProviderException {\n return readPropertyValue(edmProperty, content, null);\n }", "class_method_signature": "XmlEntityConsumer.readPropertyValue(final EdmProperty edmProperty, final InputStre...
{ "created": null, "fork": null, "fork_count": 68, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 18830102, "size": 6647, "stargazer_count": 30, "stars": null, "updates": null, "url": "https://github.com/apache/olingo-odata2" }
18830102_490
{ "fields": [ { "declarator": "LOG = Logger.getLogger(XmlEntityDeserializerTest.class.getName())", "modifier": "private static final", "original_string": "private static final Logger LOG = Logger.getLogger(XmlEntityDeserializerTest.class.getName());", "type": "Logger", "var_name": "L...
{ "body": "@SuppressWarnings(\"unchecked\")\n @Test\n public void testReadEntryRequestEmptyMapping() throws Exception {\n XmlEntityDeserializer xec = new XmlEntityDeserializer();\n\n EdmEntitySet entitySet = MockFacade.getMockEdm().getDefaultEntityContainer().getEntitySet(\"Employees\");\n InputStream cont...
{ "fields": [], "file": "odata2-lib/odata-client-core/src/main/java/org/apache/olingo/odata2/client/core/ep/deserializer/XmlEntityDeserializer.java", "identifier": "XmlEntityDeserializer", "interfaces": "", "methods": [ { "class_method_signature": "XmlEntityDeserializer.XmlEntityDeserializer()", ...
{ "body": "public ODataEntry readEntry(final EdmEntitySet entitySet, final EntityStream entity)\n throws EntityProviderException {\n XMLStreamReader reader = null;\n EntityProviderException cachedException = null;\n\n try {\n reader = XmlHelper.createStreamReader(entity.getContent());\n Entity...
{ "created": null, "fork": null, "fork_count": 68, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 18830102, "size": 6647, "stargazer_count": 30, "stars": null, "updates": null, "url": "https://github.com/apache/olingo-odata2" }
18830102_185
{ "fields": [ { "declarator": "VARIANT1 = 1", "modifier": "private final static", "original_string": "private final static int VARIANT1 = 1;", "type": "int", "var_name": "VARIANT1" }, { "declarator": "VARIANT2 = 2", "modifier": "private final static", "origi...
{ "body": "@Test\n public void testGetBuilder() {\n JPAEdmBuilder builder = objJPAEdmAssociationEnd.getBuilder();\n assertNotNull(builder);\n\n }", "class_method_signature": "JPAEdmAssociationEndTest.testGetBuilder()", "constructor": false, "full_signature": "@Test public void testGetBuilder()", "iden...
{ "fields": [ { "declarator": "entityTypeView = null", "modifier": "private", "original_string": "private JPAEdmEntityTypeView entityTypeView = null;", "type": "JPAEdmEntityTypeView", "var_name": "entityTypeView" }, { "declarator": "propertyView = null", "modifier...
{ "body": "@Override\n public JPAEdmBuilder getBuilder() {\n if (builder == null) {\n builder = new JPAEdmAssociationEndBuilder();\n }\n\n return builder;\n }", "class_method_signature": "JPAEdmAssociationEnd.getBuilder()", "constructor": false, "full_signature": "@Override public JPAEdmBuilder ...
{ "created": null, "fork": null, "fork_count": 68, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 18830102, "size": 6647, "stargazer_count": 30, "stars": null, "updates": null, "url": "https://github.com/apache/olingo-odata2" }
18830102_886
{ "fields": [ { "declarator": "NAMESPACE = \"http://www.foo.bar/Data\"", "modifier": "private static final", "original_string": "private static final String NAMESPACE = \"http://www.foo.bar/Data\";", "type": "String", "var_name": "NAMESPACE" }, { "declarator": "PREFIX =...
{ "body": "@Test\n public void testExtensionsWithAttributes() throws IOException, EntityProviderException {\n AtomServiceDocumentConsumer svcDocumentParser = new AtomServiceDocumentConsumer();\n ServiceDocument svcDocument = svcDocumentParser.readServiceDokument(createStreamReader(\"/svcExample.xml\"));\n a...
{ "fields": [ { "declarator": "currentHandledStartTagName", "modifier": "private", "original_string": "private String currentHandledStartTagName;", "type": "String", "var_name": "currentHandledStartTagName" }, { "declarator": "DEFAULT_PREFIX = \"\"", "modifier": "...
{ "body": "public ServiceDocumentImpl readServiceDokument(final XMLStreamReader reader) throws EntityProviderException {\n AtomInfoImpl atomInfo = new AtomInfoImpl();\n ServiceDocumentImpl serviceDocument = new ServiceDocumentImpl();\n List<Workspace> workspaces = new ArrayList<Workspace>();\n List<Extens...
{ "created": null, "fork": null, "fork_count": 68, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 18830102, "size": 6647, "stargazer_count": 30, "stars": null, "updates": null, "url": "https://github.com/apache/olingo-odata2" }
18830102_351
{ "fields": [ { "declarator": "DEFAULT_VALUE = \"Photo\"", "modifier": "private static final", "original_string": "private static final String DEFAULT_VALUE = \"Photo\";", "type": "String", "var_name": "DEFAULT_VALUE" }, { "declarator": "FC_TARGET_PATH = \"Содержание\";...
{ "body": "@Test(expected = EntityProviderException.class)\n public void testMissingEdmxCloseTag() throws XMLStreamException, \n EntityProviderException, EdmException, UnsupportedEncodingException {\n final String xml = \"<edmx:Edmx Version=\\\"1.0\\\" xmlns:edmx=\\\"\" + Edm.NAMESPACE_EDMX_2007_06 + \"\\\">\"\n...
{ "fields": [ { "declarator": "inscopeMap = new HashMap<String, Set<String>>()", "modifier": "private", "original_string": "private Map<String, Set<String>> inscopeMap = new HashMap<String, Set<String>>();", "type": "Map<String, Set<String>>", "var_name": "inscopeMap" }, { ...
{ "body": "public EdmDataServices readMetadata(final InputStream content, final boolean validate)//NOSONAR\n throws EntityProviderException, EdmException { \n try {\n initialize();\n EdmDataServices dataServices = new EdmDataServices();\n List<EdmSchema> schemas = new ArrayList<EdmSchema>();\n ...
{ "created": null, "fork": null, "fork_count": 68, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 18830102, "size": 6647, "stargazer_count": 30, "stars": null, "updates": null, "url": "https://github.com/apache/olingo-odata2" }
18830102_644
{ "fields": [], "file": "odata2-lib/odata-core/src/test/java/org/apache/olingo/odata2/core/edm/provider/EdmxProviderTest.java", "identifier": "EdmxProviderTest", "interfaces": "", "superclass": "" }
{ "body": "@Test\n public void nullAnnotationsAtEntityType() throws Exception {\n Edm edm = createEdm();\n assertNotNull(edm);\n EdmAnnotations annotations = edm.getEntityType(\"Self\", \"Employee\").getAnnotations();\n checkNullAnnotations(annotations);\n }", "class_method_signature": "EdmxProviderTe...
{ "fields": [ { "declarator": "dataServices", "modifier": "private", "original_string": "private DataServices dataServices;", "type": "DataServices", "var_name": "dataServices" } ], "file": "odata2-lib/odata-core/src/main/java/org/apache/olingo/odata2/core/edm/provider/EdmxPr...
{ "body": "@Override\n public EntityType getEntityType(final FullQualifiedName edmFQName) throws ODataException {\n for (Schema schema : dataServices.getSchemas()) {\n if (schema.getNamespace().equals(edmFQName.getNamespace())) {\n for (EntityType entityType : schema.getEntityTypes()) {\n if ...
{ "created": null, "fork": null, "fork_count": 68, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 18830102, "size": 6647, "stargazer_count": 30, "stars": null, "updates": null, "url": "https://github.com/apache/olingo-odata2" }
18830102_1035
{ "fields": [ { "declarator": "EMPLOYEE_1_XML =\n \"<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?>\" +\n \"<entry xmlns=\\\"\" + Edm.NAMESPACE_ATOM_2005 + \"\\\"\" +\n \" xmlns:m=\\\"\" + Edm.NAMESPACE_M_2007_08 + \"\\\"\" +\n \" xmlns:d=\\\"\" + Edm.NAMESPACE_D_2007_08 +...
{ "body": "@Test\n public void writeProperty() throws Exception {\n final EdmProperty property =\n (EdmProperty) MockFacade.getMockEdm().getEntityType(\"RefScenario\", \"Employee\").getProperty(\"EntryDate\");\n final ODataResponse result =\n new ProviderFacadeImpl().writeProperty(HttpContentType...
{ "fields": [], "file": "odata2-lib/odata-core/src/main/java/org/apache/olingo/odata2/core/ep/ProviderFacadeImpl.java", "identifier": "ProviderFacadeImpl", "interfaces": "implements EntityProviderInterface", "methods": [ { "class_method_signature": "ProviderFacadeImpl.create()", "constructor":...
{ "body": "@Override\n public ODataResponse writeProperty(final String contentType, final EdmProperty edmProperty, final Object value)\n throws EntityProviderException {\n return create(contentType).writeProperty(edmProperty, value);\n }", "class_method_signature": "ProviderFacadeImpl.writeProperty(final ...
{ "created": null, "fork": null, "fork_count": 68, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 18830102, "size": 6647, "stargazer_count": 30, "stars": null, "updates": null, "url": "https://github.com/apache/olingo-odata2" }
18830102_214
{ "fields": [ { "declarator": "METHOD_COUNT = 7", "modifier": "private static final", "original_string": "private static final int METHOD_COUNT = 7;", "type": "int", "var_name": "METHOD_COUNT" }, { "declarator": "VARIANT = 0", "modifier": "private static", "...
{ "body": "@Test\n public void testFunctionImportNoName() {\n VARIANT = 3;\n\n build();\n\n List<FunctionImport> functionImportList = jpaEdmfunctionImport.getConsistentFunctionImportList();\n\n assertEquals(functionImportList.size(), 1);\n\n FunctionImport functionImport = functionImportList.get(0);\n...
{ "fields": [ { "declarator": "consistentFunctionImportList = new ArrayList<FunctionImport>()", "modifier": "private", "original_string": "private List<FunctionImport> consistentFunctionImportList = new ArrayList<FunctionImport>();", "type": "List<FunctionImport>", "var_name": "consi...
{ "body": "@Override\n public List<FunctionImport> getConsistentFunctionImportList() {\n return consistentFunctionImportList;\n }", "class_method_signature": "JPAEdmFunctionImport.getConsistentFunctionImportList()", "constructor": false, "full_signature": "@Override public List<FunctionImport> getConsisten...
{ "created": null, "fork": null, "fork_count": 68, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 18830102, "size": 6647, "stargazer_count": 30, "stars": null, "updates": null, "url": "https://github.com/apache/olingo-odata2" }
18830102_994
{ "fields": [ { "declarator": "DEFAULT_VALUE = \"Photo\"", "modifier": "private static final", "original_string": "private static final String DEFAULT_VALUE = \"Photo\";", "type": "String", "var_name": "DEFAULT_VALUE" }, { "declarator": "FC_TARGET_PATH = \"Содержание\";...
{ "body": "@Test(expected = EntityProviderException.class)\n public void testMissingTypeAtAssociation() throws Exception {\n final String xmlWithInvalidAssociation =\n \"<edmx:Edmx Version=\\\"1.0\\\" xmlns:edmx=\\\"\"\n + Edm.NAMESPACE_EDMX_2007_06\n + \"\\\">\"\n + \"<edm...
{ "fields": [ { "declarator": "inscopeMap = new HashMap<String, Set<String>>()", "modifier": "private", "original_string": "private Map<String, Set<String>> inscopeMap = new HashMap<String, Set<String>>();", "type": "Map<String, Set<String>>", "var_name": "inscopeMap" }, { ...
{ "body": "public DataServices readMetadata(final XMLStreamReader reader, final boolean validate)\n throws EntityProviderException {\n try {\n initialize();\n DataServices dataServices = new DataServices();\n List<Schema> schemas = new ArrayList<Schema>();\n\n while (reader.hasNext()\n ...
{ "created": null, "fork": null, "fork_count": 68, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 18830102, "size": 6647, "stargazer_count": 30, "stars": null, "updates": null, "url": "https://github.com/apache/olingo-odata2" }
18830102_582
{ "fields": [ { "declarator": "BASE64_ENCODING = \"BASE64\"", "modifier": "private static final", "original_string": "private static final String BASE64_ENCODING = \"BASE64\";", "type": "String", "var_name": "BASE64_ENCODING" } ], "file": "odata2-lib/odata-core/src/test/java/...
{ "body": "@Test(expected = BatchException.class)\n public void testValidateContentTypeMissingHeader() throws BatchException {\n final Header headers = new Header(1);\n \n BatchTransformatorCommon.validateContentType(headers);\n }", "class_method_signature": "BatchTransformatorCommonTest.testValidateCont...
{ "fields": [], "file": "odata2-lib/odata-core/src/main/java/org/apache/olingo/odata2/core/batch/v2/BatchTransformatorCommon.java", "identifier": "BatchTransformatorCommon", "interfaces": "", "methods": [ { "class_method_signature": "BatchTransformatorCommon.validateContentType(final Header headers)...
{ "body": "public static void validateContentType(final Header headers) throws BatchException {\n List<String> contentTypes = headers.getHeaders(HttpHeaders.CONTENT_TYPE);\n\n if (contentTypes.isEmpty()) {\n throw new BatchException(BatchException.MISSING_CONTENT_TYPE);\n }\n if (!headers.isHeaderMat...
{ "created": null, "fork": null, "fork_count": 68, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 18830102, "size": 6647, "stargazer_count": 30, "stars": null, "updates": null, "url": "https://github.com/apache/olingo-odata2" }
18830102_428
{ "fields": [], "file": "odata2-lib/odata-client-core/src/test/java/org/apache/olingo/odata2/client/core/ep/deserializer/XmlFeedDeserializerTest.java", "identifier": "XmlFeedDeserializerTest", "interfaces": "", "superclass": "extends AbstractXmlDeserializerTest" }
{ "body": "@Test(expected = EntityProviderException.class)\n public void readEmployeesFeedWithInlineCountLetters() throws Exception {\n // prepare\n String content = readFile(\"feed_employees_full.xml\").replace(\"<m:count>6</m:count>\", \"<m:count>AAA</m:count>\");\n assertNotNull(content);\n\n EdmEntit...
{ "fields": [], "file": "odata2-lib/odata-client-core/src/main/java/org/apache/olingo/odata2/client/core/ep/deserializer/XmlFeedDeserializer.java", "identifier": "XmlFeedDeserializer", "interfaces": "", "methods": [ { "class_method_signature": "XmlFeedDeserializer.readFeed(final XMLStreamReader read...
{ "body": "public ODataDeltaFeed readFeed(final XMLStreamReader reader, final EntityInfoAggregator eia,\n final DeserializerProperties readProperties) throws EntityProviderException {\n try {\n // read xml tag\n reader.require(XMLStreamConstants.START_DOCUMENT, null, null);\n reader.nextTag();\...
{ "created": null, "fork": null, "fork_count": 68, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 18830102, "size": 6647, "stargazer_count": 30, "stars": null, "updates": null, "url": "https://github.com/apache/olingo-odata2" }
18830102_4
{ "fields": [ { "declarator": "builder = null", "modifier": "", "original_string": "JPAQueryBuilder builder = null;", "type": "JPAQueryBuilder", "var_name": "builder" } ], "file": "odata2-jpa-processor/jpa-core/src/test/java/org/apache/olingo/odata2/jpa/processor/core/access/...
{ "body": "@Test\n public void buildPutEntityTestWithoutListener() {\n try {\n EdmMapping mapping = (EdmMapping) mockMapping();\n assertNotNull(builder.build((PutMergePatchUriInfo) mockURIInfoForDeleteAndPut(mapping)));\n } catch (ODataException e) {\n fail(ODataJPATestConstants.EXCEPTION_MSG_PA...
{ "fields": [ { "declarator": "em = null", "modifier": "private", "original_string": "private EntityManager em = null;", "type": "EntityManager", "var_name": "em" }, { "declarator": "pageSize = 0", "modifier": "private", "original_string": "private int pageS...
{ "body": "public JPAQueryInfo build(GetEntitySetUriInfo uriInfo) throws ODataJPARuntimeException {\n JPAQueryInfo queryInfo = new JPAQueryInfo();\n Query query = null;\n try {\n ODataJPATombstoneEntityListener listener = getODataJPATombstoneEntityListener((UriInfo) uriInfo);\n if (listener != null...
{ "created": null, "fork": null, "fork_count": 68, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 18830102, "size": 6647, "stargazer_count": 30, "stars": null, "updates": null, "url": "https://github.com/apache/olingo-odata2" }
26861802_34
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testRemoveReferenceMany() {\n assertThat(\n catchThrowable(() -> store.removeReference(mock(ManyFeatureBean.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testRemoveReferenceMany()", "construc...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Override\n public void removeReference(SingleFeatureBean feature) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.removeReference(SingleFeatureBean feature)", "constructor": false, "full_signature": "@Override public void removeReference(SingleFeatureBean feature)", ...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_22
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void tetsValueForMany() {\n assertThat(\n catchThrowable(() -> store.valueFor(mock(ManyFeatureBean.class), mock(Object.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.tetsValueForMany()", "construct...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Nonnull\n @Override\n public <V> Optional<V> valueFor(SingleFeatureBean feature, V value) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.valueFor(SingleFeatureBean feature, V value)", "constructor": false, "full_signature": "@Nonnull @Override public Optional<V> va...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_59
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/core/DefaultPersistentEObjectTest.java", "identifier": "DefaultPersistentEObjectTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testStoreGeneration() {\n // Created without any store\n PersistentEObject object = new DefaultPersistentEObject();\n\n // Store created on first call\n assertThat(object.eStore()).isNotNull().isInstanceOf(TransientStoreAdapter.class);\n object.eStore().cl...
{ "fields": [ { "declarator": "lazyStore = Lazy.with(() -> getOrCreateStore(resource()))", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Lazy<StoreAdapter> lazyStore = Lazy.with(() -> getOrCreateStore(resource()));", "type": "Lazy<StoreAdapter>"...
{ "body": "@Nonnull\n @Override\n public StoreAdapter eStore() {\n return lazyStore.get();\n }", "class_method_signature": "DefaultPersistentEObject.eStore()", "constructor": false, "full_signature": "@Nonnull @Override public StoreAdapter eStore()", "identifier": "eStore", "invocations": [ ...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_1
{ "fields": [], "file": "neoemf-io/src/test/java/fr/inria/atlanmod/neoemf/io/proxy/ProxyClassTest.java", "identifier": "ProxyClassTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testNs() {\n String name0 = \"mc0\";\n String name1 = \"mc1\";\n\n ProxyPackage ns0 = ProxyPackage.DEFAULT;\n ProxyPackage ns1 = ProxyPackage.Registry.getInstance().register(\"prefix0\", \"uri0\");\n\n ProxyClass mc0 = new ProxyClass(ns0, name0);\n ...
{ "fields": [ { "declarator": "DEFAULT = new ProxyClass(EcorePackage.eINSTANCE.getEObject())", "modifier": "@Nonnull\n public static final", "original_string": "@Nonnull\n public static final ProxyClass DEFAULT = new ProxyClass(EcorePackage.eINSTANCE.getEObject());", "type": "ProxyCl...
{ "body": "@Nonnull\n public ProxyPackage getNamespace() {\n return ns;\n }", "class_method_signature": "ProxyClass.getNamespace()", "constructor": false, "full_signature": "@Nonnull public ProxyPackage getNamespace()", "identifier": "getNamespace", "invocations": [], "modifiers": "@Nonnull p...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_18
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testValueFor() {\n assertThat(\n catchThrowable(() -> store.valueFor(mock(SingleFeatureBean.class), mock(Object.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testValueFor()", "constructor": f...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Nonnull\n @Override\n public <V> Optional<V> valueFor(SingleFeatureBean feature, V value) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.valueFor(SingleFeatureBean feature, V value)", "constructor": false, "full_signature": "@Nonnull @Override public Optional<V> va...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_38
{ "fields": [ { "declarator": "converter", "modifier": "private", "original_string": "private AttributeConverter converter;", "type": "AttributeConverter", "var_name": "converter" } ], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/data/store/adapter/AttributeCon...
{ "body": "@Test\n void testRevertNull() {\n assertThat(converter.revert(null, mock(EAttribute.class))).isNull();\n }", "class_method_signature": "AttributeConverterTest.testRevertNull()", "constructor": false, "full_signature": "@Test void testRevertNull()", "identifier": "testRevertNull", "in...
{ "fields": [ { "declarator": "featureMapConverter", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final FeatureMapConverter featureMapConverter;", "type": "FeatureMapConverter", "var_name": "featureMapConverter" } ], "file": "neoemf-cor...
{ "body": "@Override\n public Object revert(@Nullable Object value, EAttribute attribute) {\n if (isNull(value)) {\n return null;\n }\n\n final EDataType dataType = attribute.getEAttributeType();\n\n if (!(dataType instanceof EEnum) && Primitives.isPrimitiveOrString(dataType....
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_55
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/util/EFeaturesTest.java", "identifier": "EFeaturesTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testAsReference() {\n EStructuralFeature attribute = mock(EAttribute.class);\n EStructuralFeature reference = mock(EReference.class);\n\n assertThat(EFeatures.asReference(reference)).isInstanceOf(EReference.class);\n\n assertThat(catchThrowable(() ->\n ...
{ "fields": [], "file": "neoemf-core/src/main/java/fr/inria/atlanmod/neoemf/util/EFeatures.java", "identifier": "EFeatures", "interfaces": "", "methods": [ { "class_method_signature": "EFeatures.EFeatures()", "constructor": true, "full_signature": "private EFeatures()", "identifie...
{ "body": "@Nonnull\n public static EReference asReference(EStructuralFeature feature) {\n return (EReference) feature;\n }", "class_method_signature": "EFeatures.asReference(EStructuralFeature feature)", "constructor": false, "full_signature": "@Nonnull public static EReference asReference(EStruct...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_43
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/data/bean/ManyFeatureBeanTest.java", "identifier": "ManyFeatureBeanTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testCompareEqualTo() {\n Id id0 = Id.getProvider().fromLong(42);\n\n SingleFeatureBean bean = SingleFeatureBean.of(id0, 10);\n ManyFeatureBean bean0 = bean.withPosition(0);\n ManyFeatureBean bean1 = bean.withPosition(0);\n\n assertThat(bean0).isEqualByComp...
{ "fields": [ { "declarator": "serialVersionUID = 7159493156068733506L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = 7159493156068733506L;", "type": "long", "var_name": "serialVersionUID" } ], "file": "neoemf-core/src/m...
{ "body": "@Nonnull\n public static ManyFeatureBean of(Id owner, int id, @Nonnegative int position) {\n return new ManyFeatureBean(owner, id, position);\n }", "class_method_signature": "ManyFeatureBean.of(Id owner, int id, @Nonnegative int position)", "constructor": false, "full_signature": "@Nonnu...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_14
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testSave() {\n assertThat(\n catchThrowable(() -> store.save())\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testSave()", "constructor": false, "full_signature": "@Test void testSave()", "identif...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Override\n public void save() {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.save()", "constructor": false, "full_signature": "@Override public void save()", "identifier": "save", "invocations": [ "get" ], "modifiers": "@Override public", "parameters": "...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_15
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testContainerFor() {\n assertThat(\n catchThrowable(() -> store.containerFor(mock(Id.class), mock(SingleFeatureBean.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testContainerFor()", "constru...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Override\n public void containerFor(Id id, SingleFeatureBean container) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.containerFor(Id id, SingleFeatureBean container)", "constructor": false, "full_signature": "@Override public void containerFor(Id id, SingleFeatureBe...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_42
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/data/AbstractBackendFactoryTest.java", "identifier": "AbstractBackendFactoryTest", "interfaces": "", "superclass": "extends AbstractUnitTest" }
{ "body": "@Test\n public void testCopyBackend() throws IOException {\n ImmutableConfig config = context().config();\n\n File file = currentTempFile();\n try (Backend transientBackend = new InMemoryBackendFactory().createBackend(new InMemoryUriFactory().createLocalUri(file), new InMemoryConfig...
{ "fields": [ { "declarator": "name", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final String name;", "type": "String", "var_name": "name" }, { "declarator": "supportsTransient", "modifier": "private final", "origina...
{ "body": "@Nonnull\n @Override\n public Backend createBackend(URI uri, ImmutableConfig baseConfig) {\n checkNotNull(uri, \"uri\");\n checkNotNull(baseConfig, \"baseConfig\");\n checkArgument(uri.isFile() || uri.isHierarchical(), \"URI '%s' must be either file-based or hierarchical\", uri.t...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_54
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/util/EFeaturesTest.java", "identifier": "EFeaturesTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testAsAttribute() {\n EStructuralFeature attribute = mock(EAttribute.class);\n EStructuralFeature reference = mock(EReference.class);\n\n assertThat(EFeatures.asAttribute(attribute)).isInstanceOf(EAttribute.class);\n\n assertThat(catchThrowable(() ->\n ...
{ "fields": [], "file": "neoemf-core/src/main/java/fr/inria/atlanmod/neoemf/util/EFeatures.java", "identifier": "EFeatures", "interfaces": "", "methods": [ { "class_method_signature": "EFeatures.EFeatures()", "constructor": true, "full_signature": "private EFeatures()", "identifie...
{ "body": "@Nonnull\n public static EAttribute asAttribute(EStructuralFeature feature) {\n return (EAttribute) feature;\n }", "class_method_signature": "EFeatures.asAttribute(EStructuralFeature feature)", "constructor": false, "full_signature": "@Nonnull public static EAttribute asAttribute(EStruct...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_39
{ "fields": [ { "declarator": "converter", "modifier": "private", "original_string": "private AttributeConverter converter;", "type": "AttributeConverter", "var_name": "converter" } ], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/data/store/adapter/AttributeCon...
{ "body": "@Test\n void testRevertPrimitive() {\n Class<?> type = Boolean.class;\n\n EDataType dataType = mock(EDataType.class);\n when(dataType.getInstanceClass()).thenAnswer(new Returns(type));\n\n EAttribute attribute = mock(EAttribute.class);\n when(attribute.getEAttributeTyp...
{ "fields": [ { "declarator": "featureMapConverter", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final FeatureMapConverter featureMapConverter;", "type": "FeatureMapConverter", "var_name": "featureMapConverter" } ], "file": "neoemf-cor...
{ "body": "@Override\n public Object revert(@Nullable Object value, EAttribute attribute) {\n if (isNull(value)) {\n return null;\n }\n\n final EDataType dataType = attribute.getEAttributeType();\n\n if (!(dataType instanceof EEnum) && Primitives.isPrimitiveOrString(dataType....
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_19
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testRemoveValue() {\n assertThat(\n catchThrowable(() -> store.removeValue(mock(SingleFeatureBean.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testRemoveValue()", "constructor": false, "fu...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Override\n public void removeValue(SingleFeatureBean feature) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.removeValue(SingleFeatureBean feature)", "constructor": false, "full_signature": "@Override public void removeValue(SingleFeatureBean feature)", "identifier"...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_0
{ "fields": [], "file": "neoemf-io/src/test/java/fr/inria/atlanmod/neoemf/io/proxy/ProxyClassTest.java", "identifier": "ProxyClassTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testGetDefault() {\n ProxyClass mc0 = ProxyClass.DEFAULT;\n assertThat(mc0).isNotNull();\n assertThat(mc0.getName()).isEqualTo(\"EObject\");\n assertThat(mc0.getNamespace()).isEqualTo(ProxyPackage.DEFAULT);\n }", "class_method_signature": "ProxyClassTest.tes...
{ "fields": [ { "declarator": "DEFAULT = new ProxyClass(EcorePackage.eINSTANCE.getEObject())", "modifier": "@Nonnull\n public static final", "original_string": "@Nonnull\n public static final ProxyClass DEFAULT = new ProxyClass(EcorePackage.eINSTANCE.getEObject());", "type": "ProxyCl...
{ "body": "@Nonnull\n public ProxyPackage getNamespace() {\n return ns;\n }", "class_method_signature": "ProxyClass.getNamespace()", "constructor": false, "full_signature": "@Nonnull public ProxyPackage getNamespace()", "identifier": "getNamespace", "invocations": [], "modifiers": "@Nonnull p...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_58
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/core/DefaultPersistentEObjectTest.java", "identifier": "DefaultPersistentEObjectTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testIdGeneration() {\n // Created without an undefined Id\n PersistentEObject object = new DefaultPersistentEObject();\n\n // Id generated on first call\n assertThat(object.id()).isNotSameAs(Id.UNDEFINED);\n }", "class_method_signature": "DefaultPersistentEO...
{ "fields": [ { "declarator": "lazyStore = Lazy.with(() -> getOrCreateStore(resource()))", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Lazy<StoreAdapter> lazyStore = Lazy.with(() -> getOrCreateStore(resource()));", "type": "Lazy<StoreAdapter>"...
{ "body": "@Nonnull\n @Override\n public Id id() {\n if (id == Id.UNDEFINED) { // Id#UNDEFINED is immutable\n id(Id.getProvider().generate());\n }\n return id;\n }", "class_method_signature": "DefaultPersistentEObject.id()", "constructor": false, "full_signature": "@Nonn...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_23
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testAddValue() {\n assertThat(\n catchThrowable(() -> store.addValue(mock(ManyFeatureBean.class), mock(Object.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testAddValue()", "constructor": fal...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Override\n public <V> void addValue(ManyFeatureBean feature, V value) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.addValue(ManyFeatureBean feature, V value)", "constructor": false, "full_signature": "@Override public void addValue(ManyFeatureBean feature, V value)"...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_35
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testRemoveAllReferences() {\n assertThat(\n catchThrowable(() -> store.removeAllReferences(mock(SingleFeatureBean.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testRemoveAllReferences()", "co...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Override\n public void removeAllReferences(SingleFeatureBean feature) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.removeAllReferences(SingleFeatureBean feature)", "constructor": false, "full_signature": "@Override public void removeAllReferences(SingleFeatureBean f...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_28
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testRemoveAllValues() {\n assertThat(\n catchThrowable(() -> store.removeAllValues(mock(SingleFeatureBean.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testRemoveAllValues()", "constructor": ...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Override\n public void removeAllValues(SingleFeatureBean feature) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.removeAllValues(SingleFeatureBean feature)", "constructor": false, "full_signature": "@Override public void removeAllValues(SingleFeatureBean feature)", ...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_53
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/util/EFeaturesTest.java", "identifier": "EFeaturesTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testIsReference() {\n EStructuralFeature attribute = mock(EAttribute.class);\n EStructuralFeature reference = mock(EReference.class);\n\n assertThat(EFeatures.isReference(reference)).isTrue();\n assertThat(EFeatures.isReference(attribute)).isFalse();\n }", "...
{ "fields": [], "file": "neoemf-core/src/main/java/fr/inria/atlanmod/neoemf/util/EFeatures.java", "identifier": "EFeatures", "interfaces": "", "methods": [ { "class_method_signature": "EFeatures.EFeatures()", "constructor": true, "full_signature": "private EFeatures()", "identifie...
{ "body": "public static boolean isReference(EStructuralFeature feature) {\n return feature instanceof EReference;\n }", "class_method_signature": "EFeatures.isReference(EStructuralFeature feature)", "constructor": false, "full_signature": "public static boolean isReference(EStructuralFeature feature)...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_45
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/data/bean/ManyFeatureBeanTest.java", "identifier": "ManyFeatureBeanTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testCompareGreaterThan() {\n Id id0 = Id.getProvider().fromLong(42);\n SingleFeatureBean bean = SingleFeatureBean.of(id0, 10);\n\n ManyFeatureBean bean0 = bean.withPosition(1);\n ManyFeatureBean bean1 = bean.withPosition(0);\n\n assertThat(bean0).isGreater...
{ "fields": [ { "declarator": "serialVersionUID = 7159493156068733506L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = 7159493156068733506L;", "type": "long", "var_name": "serialVersionUID" } ], "file": "neoemf-core/src/m...
{ "body": "@Nonnull\n public static ManyFeatureBean of(Id owner, int id, @Nonnegative int position) {\n return new ManyFeatureBean(owner, id, position);\n }", "class_method_signature": "ManyFeatureBean.of(Id owner, int id, @Nonnegative int position)", "constructor": false, "full_signature": "@Nonnu...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_12
{ "fields": [], "file": "neoemf-io/src/test/java/fr/inria/atlanmod/neoemf/io/util/XmiConstantsTest.java", "identifier": "XmiConstantsTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testFormatWithPrefix() {\n assertThat(XmiConstants.format(\"prefix\", \"value\")).isEqualTo(\"prefix:value\");\n }", "class_method_signature": "XmiConstantsTest.testFormatWithPrefix()", "constructor": false, "full_signature": "@Test void testFormatWithPrefix()", "identifie...
{ "fields": [ { "declarator": "ENCODING = \"utf-8\"", "modifier": "public static final", "original_string": "public static final String ENCODING = \"utf-8\";", "type": "String", "var_name": "ENCODING" }, { "declarator": "VERSION = \"1.0\"", "modifier": "public sta...
{ "body": "@Nonnull\n public static String format(@Nullable String prefix, String value) {\n checkNotNull(value, \"value\");\n\n return (isNull(prefix) ? Strings.EMPTY : prefix + ':') + value;\n }", "class_method_signature": "XmiConstants.format(@Nullable String prefix, String value)", "constr...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_32
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testAppendReference() {\n assertThat(\n catchThrowable(() -> store.appendReference(mock(SingleFeatureBean.class), mock(Id.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testAppendReference()", ...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Nonnegative\n @Override\n public int appendReference(SingleFeatureBean feature, Id reference) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.appendReference(SingleFeatureBean feature, Id reference)", "constructor": false, "full_signature": "@Nonnegative @Override p...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_24
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testAddAllValues() {\n assertThat(\n catchThrowable(() -> store.addAllValues(mock(ManyFeatureBean.class), Collections.emptyList()))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testAddAllValues()", "...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Override\n public <V> void addAllValues(ManyFeatureBean feature, List<? extends V> collection) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.addAllValues(ManyFeatureBean feature, List<? extends V> collection)", "constructor": false, "full_signature": "@Override publi...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_49
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/util/AbstractUriFactoryTest.java", "identifier": "AbstractUriFactoryTest", "interfaces": "", "superclass": "extends AbstractUnitTest" }
{ "body": "@Test\n public void testCreateUriFromStandardUri() {\n URI baseUri = URI.createURI(context().uriScheme() + \":/test\");\n URI uri = context().createUri(baseUri);\n assertThat(uri.scheme()).isEqualTo(context().uriScheme());\n }", "class_method_signature": "AbstractUriFactoryTest...
{ "fields": [ { "declarator": "scheme", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Lazy<String> scheme;", "type": "Lazy<String>", "var_name": "scheme" }, { "declarator": "supportsLocal", "modifier": "private final", ...
{ "body": "@Nonnull\n protected final String scheme() {\n return scheme.get();\n }", "class_method_signature": "AbstractUriFactory.scheme()", "constructor": false, "full_signature": "@Nonnull protected final String scheme()", "identifier": "scheme", "invocations": [ "get" ], "modifiers"...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_7
{ "fields": [], "file": "neoemf-io/src/test/java/fr/inria/atlanmod/neoemf/io/proxy/ProxyPackageTest.java", "identifier": "ProxyPackageTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testGetDefault() {\n ProxyPackage ns0 = ProxyPackage.DEFAULT;\n assertThat(ns0).isNotNull();\n assertThat(ns0.getPrefix()).isEqualTo(\"ecore\");\n }", "class_method_signature": "ProxyPackageTest.testGetDefault()", "constructor": false, "full_signature": "@Test ...
{ "fields": [ { "declarator": "DEFAULT = Registry.getInstance().register(EcorePackage.eINSTANCE)", "modifier": "@Nonnull\n public static final", "original_string": "@Nonnull\n public static final ProxyPackage DEFAULT = Registry.getInstance().register(EcorePackage.eINSTANCE);", "type"...
{ "body": "@Nonnull\n public String getPrefix() {\n return prefix;\n }", "class_method_signature": "ProxyPackage.getPrefix()", "constructor": false, "full_signature": "@Nonnull public String getPrefix()", "identifier": "getPrefix", "invocations": [], "modifiers": "@Nonnull public", "paramet...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_6
{ "fields": [], "file": "neoemf-io/src/test/java/fr/inria/atlanmod/neoemf/io/proxy/ProxyElementTest.java", "identifier": "ProxyElementTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testEquals() {\n ProxyElement elt0 = new ProxyElement();\n elt0.setId(ProxyValue.resolved(Id.getProvider().fromLong(42)));\n\n ProxyElement elt0Bis = new ProxyElement();\n elt0Bis.setId(ProxyValue.resolved(Id.getProvider().fromLong(42)));\n\n ProxyElement ...
{ "fields": [ { "declarator": "id = ProxyValue.empty()", "modifier": "@Nonnull\n private", "original_string": "@Nonnull\n private ProxyValue<Id> id = ProxyValue.empty();", "type": "ProxyValue<Id>", "var_name": "id" }, { "declarator": "metaClass", "modifier":...
{ "body": "@Override\n public boolean equals(@Nullable Object o) {\n if (this == o) {\n return true;\n }\n if (o == null || getClass() != o.getClass()) {\n return false;\n }\n\n ProxyElement that = (ProxyElement) o;\n return Objects.equals(id, that.id...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_48
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/data/bean/SingleFeatureBeanTest.java", "identifier": "SingleFeatureBeanTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testCompareGreaterThan() {\n SingleFeatureBean bean0 = SingleFeatureBean.of(Id.getProvider().fromLong(44), 10);\n SingleFeatureBean bean1 = SingleFeatureBean.of(Id.getProvider().fromLong(42), 11);\n\n assertThat(bean0).isGreaterThan(bean1);\n }", "class_method_sign...
{ "fields": [ { "declarator": "serialVersionUID = -2197099155190693261L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = -2197099155190693261L;", "type": "long", "var_name": "serialVersionUID" } ], "file": "neoemf-core/src...
{ "body": "@Nonnull\n public static SingleFeatureBean of(Id owner, int id) {\n return new SingleFeatureBean(owner, id);\n }", "class_method_signature": "SingleFeatureBean.of(Id owner, int id)", "constructor": false, "full_signature": "@Nonnull public static SingleFeatureBean of(Id owner, int id)", ...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_25
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testAppendValue() {\n assertThat(\n catchThrowable(() -> store.appendValue(mock(SingleFeatureBean.class), mock(Object.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testAppendValue()", "constr...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Nonnegative\n @Override\n public <V> int appendValue(SingleFeatureBean feature, V value) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.appendValue(SingleFeatureBean feature, V value)", "constructor": false, "full_signature": "@Nonnegative @Override public int appe...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_33
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n @SuppressWarnings(\"unchecked\")\n void testAppendAllReferences() {\n assertThat(\n catchThrowable(() -> store.appendAllReferences(mock(SingleFeatureBean.class), mock(List.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signatur...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Nonnegative\n @Override\n public int appendAllReferences(SingleFeatureBean feature, List<Id> collection) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.appendAllReferences(SingleFeatureBean feature, List<Id> collection)", "constructor": false, "full_signature": "@N...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_13
{ "fields": [], "file": "neoemf-io/src/test/java/fr/inria/atlanmod/neoemf/io/util/XmiConstantsTest.java", "identifier": "XmiConstantsTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testFormatWithoutPrefix() {\n assertThat(XmiConstants.format(null, \"value\")).isEqualTo(\"value\");\n }", "class_method_signature": "XmiConstantsTest.testFormatWithoutPrefix()", "constructor": false, "full_signature": "@Test void testFormatWithoutPrefix()", "identifier": ...
{ "fields": [ { "declarator": "ENCODING = \"utf-8\"", "modifier": "public static final", "original_string": "public static final String ENCODING = \"utf-8\";", "type": "String", "var_name": "ENCODING" }, { "declarator": "VERSION = \"1.0\"", "modifier": "public sta...
{ "body": "@Nonnull\n public static String format(@Nullable String prefix, String value) {\n checkNotNull(value, \"value\");\n\n return (isNull(prefix) ? Strings.EMPTY : prefix + ':') + value;\n }", "class_method_signature": "XmiConstants.format(@Nullable String prefix, String value)", "constr...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_44
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/data/bean/ManyFeatureBeanTest.java", "identifier": "ManyFeatureBeanTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testCompareLowerThan() {\n Id id0 = Id.getProvider().fromLong(42);\n\n SingleFeatureBean bean = SingleFeatureBean.of(id0, 10);\n ManyFeatureBean bean0 = bean.withPosition(0);\n ManyFeatureBean bean1 = bean.withPosition(1);\n\n assertThat(bean0).isLessThan(...
{ "fields": [ { "declarator": "serialVersionUID = 7159493156068733506L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = 7159493156068733506L;", "type": "long", "var_name": "serialVersionUID" } ], "file": "neoemf-core/src/m...
{ "body": "@Nonnull\n public static ManyFeatureBean of(Id owner, int id, @Nonnegative int position) {\n return new ManyFeatureBean(owner, id, position);\n }", "class_method_signature": "ManyFeatureBean.of(Id owner, int id, @Nonnegative int position)", "constructor": false, "full_signature": "@Nonnu...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_52
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/util/EFeaturesTest.java", "identifier": "EFeaturesTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testIsAttribute() {\n EStructuralFeature attribute = mock(EAttribute.class);\n EStructuralFeature reference = mock(EReference.class);\n\n assertThat(EFeatures.isAttribute(attribute)).isTrue();\n assertThat(EFeatures.isAttribute(reference)).isFalse();\n }", "...
{ "fields": [], "file": "neoemf-core/src/main/java/fr/inria/atlanmod/neoemf/util/EFeatures.java", "identifier": "EFeatures", "interfaces": "", "methods": [ { "class_method_signature": "EFeatures.EFeatures()", "constructor": true, "full_signature": "private EFeatures()", "identifie...
{ "body": "public static boolean isAttribute(EStructuralFeature feature) {\n return feature instanceof EAttribute;\n }", "class_method_signature": "EFeatures.isAttribute(EStructuralFeature feature)", "constructor": false, "full_signature": "public static boolean isAttribute(EStructuralFeature feature)...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_29
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testReferenceForMany() {\n assertThat(\n catchThrowable(() -> store.referenceFor(mock(ManyFeatureBean.class), mock(Id.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testReferenceForMany()", "c...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Nonnull\n @Override\n public Optional<Id> referenceFor(SingleFeatureBean feature, Id reference) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.referenceFor(SingleFeatureBean feature, Id reference)", "constructor": false, "full_signature": "@Nonnull @Override public...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_9
{ "fields": [], "file": "neoemf-io/src/test/java/fr/inria/atlanmod/neoemf/io/proxy/ProxyPackageTest.java", "identifier": "ProxyPackageTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testEquals() {\n String prefix0 = \"prefix0\";\n String prefix1 = \"prefix1\";\n\n String uri0 = \"uri0\";\n String uri1 = \"uri1\";\n\n ProxyPackage ns0 = ProxyPackage.Registry.getInstance().register(prefix0, uri0);\n ProxyPackage ns0Bis = ProxyPac...
{ "fields": [ { "declarator": "DEFAULT = Registry.getInstance().register(EcorePackage.eINSTANCE)", "modifier": "@Nonnull\n public static final", "original_string": "@Nonnull\n public static final ProxyPackage DEFAULT = Registry.getInstance().register(EcorePackage.eINSTANCE);", "type"...
{ "body": "@Override\n public boolean equals(@Nullable Object o) {\n if (this == o) {\n return true;\n }\n if (o == null || getClass() != o.getClass()) {\n return false;\n }\n\n ProxyPackage that = (ProxyPackage) o;\n return Objects.equals(uri, that.u...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_10
{ "fields": [], "file": "neoemf-io/src/test/java/fr/inria/atlanmod/neoemf/io/proxy/ProxyPackageTest.java", "identifier": "ProxyPackageTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testToString() {\n String prefix0 = \"prefix0\";\n String uri0 = \"uri0\";\n\n ProxyPackage ns0 = ProxyPackage.Registry.getInstance().register(prefix0, uri0);\n assertThat(ns0).hasToString(\"prefix0@uri0\");\n }", "class_method_signature": "ProxyPackageTest....
{ "fields": [ { "declarator": "DEFAULT = Registry.getInstance().register(EcorePackage.eINSTANCE)", "modifier": "@Nonnull\n public static final", "original_string": "@Nonnull\n public static final ProxyPackage DEFAULT = Registry.getInstance().register(EcorePackage.eINSTANCE);", "type"...
{ "body": "@Override\n public String toString() {\n return prefix + '@' + uri;\n }", "class_method_signature": "ProxyPackage.toString()", "constructor": false, "full_signature": "@Override public String toString()", "identifier": "toString", "invocations": [], "modifiers": "@Override public",...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_47
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/data/bean/SingleFeatureBeanTest.java", "identifier": "SingleFeatureBeanTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testCompareLowerThan() {\n Id id0 = Id.getProvider().fromLong(42);\n\n SingleFeatureBean bean0 = SingleFeatureBean.of(id0, 10);\n SingleFeatureBean bean1 = SingleFeatureBean.of(id0, 11);\n\n assertThat(bean0).isLessThan(bean1);\n }", "class_method_signature"...
{ "fields": [ { "declarator": "serialVersionUID = -2197099155190693261L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = -2197099155190693261L;", "type": "long", "var_name": "serialVersionUID" } ], "file": "neoemf-core/src...
{ "body": "@Nonnull\n public static SingleFeatureBean of(Id owner, int id) {\n return new SingleFeatureBean(owner, id);\n }", "class_method_signature": "SingleFeatureBean.of(Id owner, int id)", "constructor": false, "full_signature": "@Nonnull public static SingleFeatureBean of(Id owner, int id)", ...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_51
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/util/AbstractUriFactoryTest.java", "identifier": "AbstractUriFactoryTest", "interfaces": "", "superclass": "extends AbstractUnitTest" }
{ "body": "@Test\n public void testCreateFileUriFromFile() throws IOException {\n URI uri = context().createUri(currentTempFile());\n assertThat(uri.scheme()).isEqualTo(context().uriScheme());\n }", "class_method_signature": "AbstractUriFactoryTest.testCreateFileUriFromFile()", "constructor": ...
{ "fields": [ { "declarator": "scheme", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Lazy<String> scheme;", "type": "Lazy<String>", "var_name": "scheme" }, { "declarator": "supportsLocal", "modifier": "private final", ...
{ "body": "@Nonnull\n protected final String scheme() {\n return scheme.get();\n }", "class_method_signature": "AbstractUriFactory.scheme()", "constructor": false, "full_signature": "@Nonnull protected final String scheme()", "identifier": "scheme", "invocations": [ "get" ], "modifiers"...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_5
{ "fields": [], "file": "neoemf-io/src/test/java/fr/inria/atlanmod/neoemf/io/proxy/ProxyElementTest.java", "identifier": "ProxyElementTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testHashCode() {\n ProxyElement elt0 = new ProxyElement();\n elt0.setId(ProxyValue.resolved(Id.getProvider().fromLong(42)));\n\n ProxyElement elt0Bis = new ProxyElement();\n elt0Bis.setId(ProxyValue.resolved(Id.getProvider().fromLong(42)));\n\n ProxyElemen...
{ "fields": [ { "declarator": "id = ProxyValue.empty()", "modifier": "@Nonnull\n private", "original_string": "@Nonnull\n private ProxyValue<Id> id = ProxyValue.empty();", "type": "ProxyValue<Id>", "var_name": "id" }, { "declarator": "metaClass", "modifier":...
{ "body": "@Override\n public int hashCode() {\n return Objects.hash(id);\n }", "class_method_signature": "ProxyElement.hashCode()", "constructor": false, "full_signature": "@Override public int hashCode()", "identifier": "hashCode", "invocations": [ "hash" ], "modifiers": "@Override pu...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_26
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testAppendAllValues() {\n assertThat(\n catchThrowable(() -> store.appendAllValues(mock(SingleFeatureBean.class), Collections.emptyList()))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testAppendAllVal...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Nonnegative\n @Override\n public <V> int appendAllValues(SingleFeatureBean feature, List<? extends V> collection) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.appendAllValues(SingleFeatureBean feature, List<? extends V> collection)", "constructor": false, "full_s...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_30
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testAddReference() {\n assertThat(\n catchThrowable(() -> store.addReference(mock(ManyFeatureBean.class), mock(Id.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testAddReference()", "construct...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Override\n public void addReference(ManyFeatureBean feature, Id reference) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.addReference(ManyFeatureBean feature, Id reference)", "constructor": false, "full_signature": "@Override public void addReference(ManyFeatureBean ...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_31
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n @SuppressWarnings(\"unchecked\")\n void testAddAllReferences() {\n assertThat(\n catchThrowable(() -> store.addAllReferences(mock(ManyFeatureBean.class), mock(List.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "Rea...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Override\n public void addAllReferences(ManyFeatureBean feature, List<Id> collection) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.addAllReferences(ManyFeatureBean feature, List<Id> collection)", "constructor": false, "full_signature": "@Override public void addAllR...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_27
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testRemoveValueMany() {\n assertThat(\n catchThrowable(() -> store.removeValue(mock(ManyFeatureBean.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testRemoveValueMany()", "constructor": false,...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Override\n public void removeValue(SingleFeatureBean feature) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.removeValue(SingleFeatureBean feature)", "constructor": false, "full_signature": "@Override public void removeValue(SingleFeatureBean feature)", "identifier"...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_4
{ "fields": [], "file": "neoemf-io/src/test/java/fr/inria/atlanmod/neoemf/io/proxy/ProxyClassTest.java", "identifier": "ProxyClassTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testToString() {\n String name0 = \"mc0\";\n String prefix0 = \"uri0\";\n\n ProxyPackage ns0 = ProxyPackage.Registry.getInstance().register(prefix0, \"uri0\");\n\n ProxyClass mc0 = new ProxyClass(ns0, name0);\n\n assertThat(mc0).hasToString(\"uri0:mc0\");\...
{ "fields": [ { "declarator": "DEFAULT = new ProxyClass(EcorePackage.eINSTANCE.getEObject())", "modifier": "@Nonnull\n public static final", "original_string": "@Nonnull\n public static final ProxyClass DEFAULT = new ProxyClass(EcorePackage.eINSTANCE.getEObject());", "type": "ProxyCl...
{ "body": "@Override\n public String toString() {\n return ns.getPrefix() + ':' + getName();\n }", "class_method_signature": "ProxyClass.toString()", "constructor": false, "full_signature": "@Override public String toString()", "identifier": "toString", "invocations": [ "getPrefix", "ge...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_50
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/util/AbstractUriFactoryTest.java", "identifier": "AbstractUriFactoryTest", "interfaces": "", "superclass": "extends AbstractUnitTest" }
{ "body": "@Test\n public void testCreateUriFromFileUri() throws IOException {\n URI baseUri = URI.createFileURI(currentTempFile().getAbsolutePath());\n URI uri = context().createUri(baseUri);\n assertThat(uri.scheme()).isEqualTo(context().uriScheme());\n }", "class_method_signature": "Ab...
{ "fields": [ { "declarator": "scheme", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Lazy<String> scheme;", "type": "Lazy<String>", "var_name": "scheme" }, { "declarator": "supportsLocal", "modifier": "private final", ...
{ "body": "@Nonnull\n protected final String scheme() {\n return scheme.get();\n }", "class_method_signature": "AbstractUriFactory.scheme()", "constructor": false, "full_signature": "@Nonnull protected final String scheme()", "identifier": "scheme", "invocations": [ "get" ], "modifiers"...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_46
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/data/bean/SingleFeatureBeanTest.java", "identifier": "SingleFeatureBeanTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testCompareEqualTo() {\n Id id0 = Id.getProvider().fromLong(42);\n\n SingleFeatureBean bean0 = SingleFeatureBean.of(id0, 10);\n SingleFeatureBean bean1 = SingleFeatureBean.of(id0, 10);\n\n assertThat(bean0).isEqualByComparingTo(bean1);\n }", "class_method_si...
{ "fields": [ { "declarator": "serialVersionUID = -2197099155190693261L", "modifier": "private static final", "original_string": "private static final long serialVersionUID = -2197099155190693261L;", "type": "long", "var_name": "serialVersionUID" } ], "file": "neoemf-core/src...
{ "body": "@Nonnull\n public static SingleFeatureBean of(Id owner, int id) {\n return new SingleFeatureBean(owner, id);\n }", "class_method_signature": "SingleFeatureBean.of(Id owner, int id)", "constructor": false, "full_signature": "@Nonnull public static SingleFeatureBean of(Id owner, int id)", ...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_11
{ "fields": [], "file": "neoemf-io/src/test/java/fr/inria/atlanmod/neoemf/io/proxy/ProxyReferenceTest.java", "identifier": "ProxyReferenceTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testContainment() {\n ProxyReference ref0 = new ProxyReference();\n ref0.setName(\"reference0\");\n assertThat(ref0.isContainment()).isFalse();\n\n ref0.isContainment(true);\n assertThat(ref0.isContainment()).isTrue();\n\n ref0.isContainment(false);...
{ "fields": [ { "declarator": "containment", "modifier": "private", "original_string": "private boolean containment;", "type": "boolean", "var_name": "containment" } ], "file": "neoemf-io/src/main/java/fr/inria/atlanmod/neoemf/io/proxy/ProxyReference.java", "identifier": "P...
{ "body": "public boolean isContainment() {\n return containment;\n }", "class_method_signature": "ProxyReference.isContainment()", "constructor": false, "full_signature": "public boolean isContainment()", "identifier": "isContainment", "invocations": [], "modifiers": "public", "parameters": "...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_8
{ "fields": [], "file": "neoemf-io/src/test/java/fr/inria/atlanmod/neoemf/io/proxy/ProxyPackageTest.java", "identifier": "ProxyPackageTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testHashCode() {\n String prefix0 = \"prefix0\";\n String prefix1 = \"prefix1\";\n\n String uri0 = \"uri0\";\n String uri1 = \"uri1\";\n\n ProxyPackage ns0 = ProxyPackage.Registry.getInstance().register(prefix0, uri0);\n ProxyPackage ns0Bis = ProxyP...
{ "fields": [ { "declarator": "DEFAULT = Registry.getInstance().register(EcorePackage.eINSTANCE)", "modifier": "@Nonnull\n public static final", "original_string": "@Nonnull\n public static final ProxyPackage DEFAULT = Registry.getInstance().register(EcorePackage.eINSTANCE);", "type"...
{ "body": "@Override\n public int hashCode() {\n return Objects.hash(uri);\n }", "class_method_signature": "ProxyPackage.hashCode()", "constructor": false, "full_signature": "@Override public int hashCode()", "identifier": "hashCode", "invocations": [ "hash" ], "modifiers": "@Override p...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_3
{ "fields": [], "file": "neoemf-io/src/test/java/fr/inria/atlanmod/neoemf/io/proxy/ProxyClassTest.java", "identifier": "ProxyClassTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testEquals() {\n String name0 = \"mc0\";\n String name1 = \"mc1\";\n\n ProxyPackage ns0 = ProxyPackage.DEFAULT;\n\n ProxyClass mc0 = new ProxyClass(ns0, name0);\n ProxyClass mc0Bis = new ProxyClass(ns0, name0);\n ProxyClass mc1 = new ProxyClass(ns0,...
{ "fields": [ { "declarator": "DEFAULT = new ProxyClass(EcorePackage.eINSTANCE.getEObject())", "modifier": "@Nonnull\n public static final", "original_string": "@Nonnull\n public static final ProxyClass DEFAULT = new ProxyClass(EcorePackage.eINSTANCE.getEObject());", "type": "ProxyCl...
{ "body": "@Override\n public boolean equals(@Nullable Object o) {\n if (this == o) {\n return true;\n }\n if (o == null || getClass() != o.getClass()) {\n return false;\n }\n if (!super.equals(o)) {\n return false;\n }\n\n ProxyClas...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_20
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testReferenceFor() {\n assertThat(\n catchThrowable(() -> store.referenceFor(mock(SingleFeatureBean.class), mock(Id.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testReferenceFor()", "constru...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Nonnull\n @Override\n public Optional<Id> referenceFor(SingleFeatureBean feature, Id reference) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.referenceFor(SingleFeatureBean feature, Id reference)", "constructor": false, "full_signature": "@Nonnull @Override public...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_36
{ "fields": [ { "declarator": "converter", "modifier": "private", "original_string": "private AttributeConverter converter;", "type": "AttributeConverter", "var_name": "converter" } ], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/data/store/adapter/AttributeCon...
{ "body": "@Test\n void testConvertNull() {\n assertThat(converter.convert(null, mock(EAttribute.class))).isNull();\n }", "class_method_signature": "AttributeConverterTest.testConvertNull()", "constructor": false, "full_signature": "@Test void testConvertNull()", "identifier": "testConvertNull", ...
{ "fields": [ { "declarator": "featureMapConverter", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final FeatureMapConverter featureMapConverter;", "type": "FeatureMapConverter", "var_name": "featureMapConverter" } ], "file": "neoemf-cor...
{ "body": "@Override\n public Object convert(@Nullable Object value, EAttribute attribute) {\n if (isNull(value)) {\n return null;\n }\n\n final EDataType dataType = attribute.getEAttributeType();\n\n if (!(dataType instanceof EEnum) && Primitives.isPrimitiveOrString(dataType...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_61
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/core/DefaultPersistentEObjectTest.java", "identifier": "DefaultPersistentEObjectTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testEquals() {\n Id id = Id.getProvider().fromLong(17L);\n\n PersistentEObject o0 = new DefaultPersistentEObject(id);\n PersistentEObject o1 = new DefaultPersistentEObject(id);\n PersistentEObject o2 = new DefaultPersistentEObject();\n\n assertThat(o0).isE...
{ "fields": [ { "declarator": "lazyStore = Lazy.with(() -> getOrCreateStore(resource()))", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Lazy<StoreAdapter> lazyStore = Lazy.with(() -> getOrCreateStore(resource()));", "type": "Lazy<StoreAdapter>"...
{ "body": "@Override\n public boolean equals(@Nullable Object o) {\n if (this == o) {\n return true;\n }\n if (!(o instanceof PersistentEObject)) {\n return false;\n }\n\n PersistentEObject that = (PersistentEObject) o;\n return Objects.equals(id(), t...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_16
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testRemoveContainer() {\n assertThat(\n catchThrowable(() -> store.removeContainer(mock(Id.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testRemoveContainer()", "constructor": false, "full_...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Override\n public void removeContainer(Id id) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.removeContainer(Id id)", "constructor": false, "full_signature": "@Override public void removeContainer(Id id)", "identifier": "removeContainer", "invocations": [ "get...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_41
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/data/AbstractBackendFactoryTest.java", "identifier": "AbstractBackendFactoryTest", "interfaces": "", "superclass": "extends AbstractUnitTest" }
{ "body": "@Test\n public void testCreatePersistentStore() throws IOException {\n try (Backend backend = context().factory().createBackend(context().createUri(currentTempFile()), context().config())) {\n try (Store store = StoreFactory.getInstance().createStore(backend, context().config())) {\n ...
{ "fields": [ { "declarator": "name", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final String name;", "type": "String", "var_name": "name" }, { "declarator": "supportsTransient", "modifier": "private final", "origina...
{ "body": "@Nonnull\n @Override\n public Backend createBackend(URI uri, ImmutableConfig baseConfig) {\n checkNotNull(uri, \"uri\");\n checkNotNull(baseConfig, \"baseConfig\");\n checkArgument(uri.isFile() || uri.isHierarchical(), \"URI '%s' must be either file-based or hierarchical\", uri.t...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_57
{ "fields": [ { "declarator": "eClass", "modifier": "private static", "original_string": "private static EClass eClass;", "type": "EClass", "var_name": "eClass" } ], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/core/PersistenceFactoryTest.java", "identifier":...
{ "body": "@Test\n void createWithClassAndId() {\n Id id = Id.getProvider().fromLong(17L);\n\n PersistentEObject object = PersistenceFactory.newInstance(eClass, id);\n\n assertThat(object.eClass()).isEqualTo(eClass);\n assertThat(object.id()).isEqualTo(id);\n }", "class_method_sign...
{ "fields": [], "file": "neoemf-core/src/main/java/fr/inria/atlanmod/neoemf/core/PersistenceFactory.java", "identifier": "PersistenceFactory", "interfaces": "implements EFactory", "methods": [ { "class_method_signature": "PersistenceFactory.PersistenceFactory()", "constructor": true, "fu...
{ "body": "@Nonnull\n public static PersistentEObject newInstance(EClass eClass) {\n return newInstance(eClass, Id.UNDEFINED);\n }", "class_method_signature": "PersistenceFactory.newInstance(EClass eClass)", "constructor": false, "full_signature": "@Nonnull public static PersistentEObject newInstan...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_56
{ "fields": [ { "declarator": "eClass", "modifier": "private static", "original_string": "private static EClass eClass;", "type": "EClass", "var_name": "eClass" } ], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/core/PersistenceFactoryTest.java", "identifier":...
{ "body": "@Test\n void createWithClassOnly() {\n PersistentEObject object = PersistenceFactory.newInstance(eClass);\n\n assertThat(object.eClass()).isEqualTo(eClass);\n }", "class_method_signature": "PersistenceFactoryTest.createWithClassOnly()", "constructor": false, "full_signature": "@Te...
{ "fields": [], "file": "neoemf-core/src/main/java/fr/inria/atlanmod/neoemf/core/PersistenceFactory.java", "identifier": "PersistenceFactory", "interfaces": "implements EFactory", "methods": [ { "class_method_signature": "PersistenceFactory.PersistenceFactory()", "constructor": true, "fu...
{ "body": "@Nonnull\n public static PersistentEObject newInstance(EClass eClass) {\n return newInstance(eClass, Id.UNDEFINED);\n }", "class_method_signature": "PersistenceFactory.newInstance(EClass eClass)", "constructor": false, "full_signature": "@Nonnull public static PersistentEObject newInstan...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_40
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/data/AbstractBackendFactoryTest.java", "identifier": "AbstractBackendFactoryTest", "interfaces": "", "superclass": "extends AbstractUnitTest" }
{ "body": "@Test\n public void testCreateTransientStore() throws IOException {\n try (Backend backend = new InMemoryBackendFactory().createBackend(new InMemoryUriFactory().createLocalUri(currentTempFile()), new InMemoryConfig())) {\n try (Store store = StoreFactory.getInstance().createStore(backe...
{ "fields": [ { "declarator": "name", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final String name;", "type": "String", "var_name": "name" }, { "declarator": "supportsTransient", "modifier": "private final", "origina...
{ "body": "@Nonnull\n @Override\n public Backend createBackend(URI uri, ImmutableConfig baseConfig) {\n checkNotNull(uri, \"uri\");\n checkNotNull(baseConfig, \"baseConfig\");\n checkArgument(uri.isFile() || uri.isHierarchical(), \"URI '%s' must be either file-based or hierarchical\", uri.t...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_17
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testmMetaClassFor() {\n assertThat(\n catchThrowable(() -> store.metaClassFor(mock(Id.class), mock(ClassBean.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testmMetaClassFor()", "constructor":...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Override\n public boolean metaClassFor(Id id, ClassBean metaClass) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.metaClassFor(Id id, ClassBean metaClass)", "constructor": false, "full_signature": "@Override public boolean metaClassFor(Id id, ClassBean metaClass)", ...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_60
{ "fields": [], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/core/DefaultPersistentEObjectTest.java", "identifier": "DefaultPersistentEObjectTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testHashCode() {\n Id id0 = Id.getProvider().fromLong(17L);\n Id id1 = Id.getProvider().fromLong(44L);\n\n PersistentEObject o0 = new DefaultPersistentEObject(id0);\n PersistentEObject o1 = new DefaultPersistentEObject(id0);\n PersistentEObject o2 = new De...
{ "fields": [ { "declarator": "lazyStore = Lazy.with(() -> getOrCreateStore(resource()))", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Lazy<StoreAdapter> lazyStore = Lazy.with(() -> getOrCreateStore(resource()));", "type": "Lazy<StoreAdapter>"...
{ "body": "@Override\n public int hashCode() {\n return Objects.hash(id());\n }", "class_method_signature": "DefaultPersistentEObject.hashCode()", "constructor": false, "full_signature": "@Override public int hashCode()", "identifier": "hashCode", "invocations": [ "hash", "id" ], "m...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_37
{ "fields": [ { "declarator": "converter", "modifier": "private", "original_string": "private AttributeConverter converter;", "type": "AttributeConverter", "var_name": "converter" } ], "file": "neoemf-core/src/test/java/fr/inria/atlanmod/neoemf/data/store/adapter/AttributeCon...
{ "body": "@Test\n void testConvertPrimitive() {\n Class<?> type = Boolean.class;\n\n EDataType dataType = mock(EDataType.class);\n when(dataType.getInstanceClass()).thenAnswer(new Returns(type));\n\n EAttribute attribute = mock(EAttribute.class);\n when(attribute.getEAttributeTy...
{ "fields": [ { "declarator": "featureMapConverter", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final FeatureMapConverter featureMapConverter;", "type": "FeatureMapConverter", "var_name": "featureMapConverter" } ], "file": "neoemf-cor...
{ "body": "@Override\n public Object convert(@Nullable Object value, EAttribute attribute) {\n if (isNull(value)) {\n return null;\n }\n\n final EDataType dataType = attribute.getEAttributeType();\n\n if (!(dataType instanceof EEnum) && Primitives.isPrimitiveOrString(dataType...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_21
{ "fields": [ { "declarator": "READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class", "modifier": "private static final", "original_string": "private static final Class<? extends Throwable> READONLY_EXCEPTION_TYPE = UnsupportedOperationException.class;", "type": "Class<? extends T...
{ "body": "@Test\n void testRemoveReference() {\n assertThat(\n catchThrowable(() -> store.removeReference(mock(SingleFeatureBean.class)))\n ).isExactlyInstanceOf(READONLY_EXCEPTION_TYPE);\n }", "class_method_signature": "ReadOnlyStoreTest.testRemoveReference()", "constructor": ...
{ "fields": [ { "declarator": "e = () -> new UnsupportedOperationException(\"Operation forbidden in read-only mode\")", "modifier": "@Nonnull\n private final", "original_string": "@Nonnull\n private final Supplier<RuntimeException> e = () -> new UnsupportedOperationException(\"Operation fo...
{ "body": "@Override\n public void removeReference(SingleFeatureBean feature) {\n throw e.get();\n }", "class_method_signature": "ReadOnlyStore.removeReference(SingleFeatureBean feature)", "constructor": false, "full_signature": "@Override public void removeReference(SingleFeatureBean feature)", ...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
26861802_2
{ "fields": [], "file": "neoemf-io/src/test/java/fr/inria/atlanmod/neoemf/io/proxy/ProxyClassTest.java", "identifier": "ProxyClassTest", "interfaces": "", "superclass": "extends AbstractTest" }
{ "body": "@Test\n void testHashCode() {\n String name0 = \"mc0\";\n String name1 = \"mc1\";\n\n ProxyPackage ns0 = ProxyPackage.DEFAULT;\n\n ProxyClass mc0 = new ProxyClass(ns0, name0);\n ProxyClass mc0Bis = new ProxyClass(ns0, name0);\n ProxyClass mc1 = new ProxyClass(ns...
{ "fields": [ { "declarator": "DEFAULT = new ProxyClass(EcorePackage.eINSTANCE.getEObject())", "modifier": "@Nonnull\n public static final", "original_string": "@Nonnull\n public static final ProxyClass DEFAULT = new ProxyClass(EcorePackage.eINSTANCE.getEObject());", "type": "ProxyCl...
{ "body": "@Override\n public int hashCode() {\n return Objects.hash(super.hashCode(), ns);\n }", "class_method_signature": "ProxyClass.hashCode()", "constructor": false, "full_signature": "@Override public int hashCode()", "identifier": "hashCode", "invocations": [ "hash", "hashCode" ...
{ "created": null, "fork": null, "fork_count": 12, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 26861802, "size": 718304, "stargazer_count": 37, "stars": null, "updates": null, "url": "https://github.com/atlanmod/NeoEMF" }
21871478_286
{ "fields": [ { "declarator": "frameType = APIFrameType.SEND_DATA_REQUEST.getValue()", "modifier": "private", "original_string": "private int frameType = APIFrameType.SEND_DATA_REQUEST.getValue();", "type": "int", "var_name": "frameType" }, { "declarator": "frameID = 0x...
{ "body": "@Test\n\tpublic final void testGetAPIPacketParameters() {\n\t\t// Set up the resources for the test.\n\t\tSendDataRequestPacket packet = new SendDataRequestPacket(frameID, path, contentType, options, data);\n\n\t\t// Call the method under test.\n\t\tLinkedHashMap<String, String> packetParams = packet.getAP...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 6", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 6;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "ERROR_PAYLOAD_NULL = \"Send...
{ "body": "@Override\n\tpublic LinkedHashMap<String, String> getAPIPacketParameters() {\n\t\tLinkedHashMap<String, String> parameters = new LinkedHashMap<String, String>();\n\t\tif (path != null) {\n\t\t\tparameters.put(\"Path length\", HexUtils.prettyHexString(HexUtils.integerToHexString(path.length(), 1)) + \" (\" ...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_99
{ "fields": [ { "declarator": "exception = ExpectedException.none()", "modifier": "@Rule\n\tpublic", "original_string": "@Rule\n\tpublic ExpectedException exception = ExpectedException.none();", "type": "ExpectedException", "var_name": "exception" } ], "file": "library/src/te...
{ "body": "@Test\n\tpublic final void testCreatePacketPayloadNotIncludingFrameType() {\n\t\t// Setup the resources for the test.\n\t\tXBee64BitAddress source64Addr = new XBee64BitAddress(\"0013A2004032D9AB\");\n\t\tXBee16BitAddress source16Addr = new XBee16BitAddress(\"D817\");\n\t\tint options = 40;\n\t\tbyte[] data...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 12", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 12;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "sourceAddress64", "...
{ "body": "public static ReceivePacket createPacket(byte[] payload) {\n\t\tif (payload == null)\n\t\t\tthrow new NullPointerException(\"Receive packet payload cannot be null.\");\n\t\t\n\t\t// 1 (Frame type) + 8 (32-bit address) + 2 (16-bit address) + 1 (receive options)\n\t\tif (payload.length < MIN_API_PAYLOAD_LENG...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_76
{ "fields": [ { "declarator": "exception = ExpectedException.none()", "modifier": "@Rule\n\tpublic", "original_string": "@Rule\n\tpublic ExpectedException exception = ExpectedException.none();", "type": "ExpectedException", "var_name": "exception" } ], "file": "library/src/te...
{ "body": "@Test\n\tpublic final void testGetAPIPacketParametersATCommandParameterByteArray() {\n\t\t// Setup the resources for the test.\n\t\tint frameID = 0x10;\n\t\tString command = \"NI\";\n\t\tbyte[] parameter = new byte[]{0x6D, 0x79, 0x44, 0x65, 0x76, 0x69, 0x63, 0x65};\n\t\tATCommandQueuePacket packet = new AT...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 4", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 4;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "command", "modifier":...
{ "body": "@Override\n\tpublic LinkedHashMap<String, String> getAPIPacketParameters() {\n\t\tLinkedHashMap<String, String> parameters = new LinkedHashMap<String, String>();\n\t\tparameters.put(\"AT Command\", HexUtils.prettyHexString(HexUtils.byteArrayToHexString(command.getBytes())) + \" (\" + command + \")\");\n\t\...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_269
{ "fields": [ { "declarator": "frameType = APIFrameType.SEND_DATA_RESPONSE.getValue()", "modifier": "private", "original_string": "private int frameType = APIFrameType.SEND_DATA_RESPONSE.getValue();", "type": "int", "var_name": "frameType" }, { "declarator": "frameID = ...
{ "body": "@Test\n\tpublic final void testGetAPIPacketParameters() {\n\t\t// Set up the resources for the test.\n\t\tSendDataResponsePacket packet = new SendDataResponsePacket(frameID, status);\n\n\t\t// Call the method under test.\n\t\tLinkedHashMap<String, String> packetParams = packet.getAPIPacketParameters();\n\n...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 3", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 3;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "ERROR_PAYLOAD_NULL = \"Send...
{ "body": "@Override\n\tpublic LinkedHashMap<String, String> getAPIPacketParameters() {\n\t\tLinkedHashMap<String, String> parameters = new LinkedHashMap<String, String>();\n\t\tparameters.put(\"Status\", HexUtils.prettyHexString(HexUtils.integerToHexString(status.getID(), 1)) + \" (\" + status.getName() + \")\");\n\...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_793
{ "fields": [ { "declarator": "MAX_LENGTH = XBeePacketsQueue.DEFAULT_MAX_LENGTH", "modifier": "private final static", "original_string": "private final static int MAX_LENGTH = XBeePacketsQueue.DEFAULT_MAX_LENGTH;", "type": "int", "var_name": "MAX_LENGTH" }, { "declarato...
{ "body": "@Test\n\tpublic void testGetFirstIPv6DataPacket() {\n\t\t// Create an XBeePacketsQueue of 5 slots.\n\t\tXBeePacketsQueue xbeePacketsQueue = new XBeePacketsQueue(5);\n\t\t\n\t\t// Add 2 dummy packets.\n\t\tfor (int i = 0; i < 2; i ++)\n\t\t\txbeePacketsQueue.addPacket(Mockito.mock(XBeePacket.class));\n\t\t\...
{ "fields": [ { "declarator": "DEFAULT_MAX_LENGTH = 50", "modifier": "public static final", "original_string": "public static final int DEFAULT_MAX_LENGTH = 50;", "type": "int", "var_name": "DEFAULT_MAX_LENGTH" }, { "declarator": "maxLength = DEFAULT_MAX_LENGTH", ...
{ "body": "public XBeePacket getFirstIPv6DataPacket(int timeout) {\n\t\tif (timeout > 0) {\n\t\t\tXBeePacket xbeePacket = getFirstIPv6DataPacket(0);\n\t\t\t// Wait for a timeout or until a IPv6 data packet is read.\n\t\t\tLong deadLine = System.currentTimeMillis() + timeout;\n\t\t\twhile (xbeePacket == null && deadLi...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_639
{ "fields": [ { "declarator": "PARAMETER_AI = \"AI\"", "modifier": "private static final", "original_string": "private static final String PARAMETER_AI = \"AI\";", "type": "String", "var_name": "PARAMETER_AI" }, { "declarator": "PARAMETER_MA = \"MA\"", "modifier":...
{ "body": "@Test\n\tpublic void testGetIPAddressMaskIllegalIP() throws XBeeException {\n\t\t// Return an illegal IP address when getting the MK parameter.\n\t\tMockito.doReturn(new byte[]{0x00}).when(wifiDevice).getParameter(PARAMETER_MK);\n\n\t\t// Get the IP address mask of the device.\n\t\ttry {\n\t\t\twifiDevice....
{ "fields": [ { "declarator": "DEFAULT_ACCESS_POINT_TIMETOUT = 15000", "modifier": "private final static", "original_string": "private final static int DEFAULT_ACCESS_POINT_TIMETOUT = 15000;", "type": "int", "var_name": "DEFAULT_ACCESS_POINT_TIMETOUT" }, { "declarator":...
{ "body": "public Inet4Address getIPAddressMask() throws TimeoutException, XBeeException {\n\t\ttry {\n\t\t\treturn (Inet4Address) Inet4Address.getByAddress(getParameter(\"MK\"));\n\t\t} catch (UnknownHostException e) {\n\t\t\tthrow new XBeeException(e);\n\t\t}\n\t}", "class_method_signature": "WiFiDevice.getIPAddr...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_510
{ "fields": [ { "declarator": "exception = ExpectedException.none()", "modifier": "@Rule\n\tpublic", "original_string": "@Rule\n\tpublic ExpectedException exception = ExpectedException.none();", "type": "ExpectedException", "var_name": "exception" } ], "file": "library/src/te...
{ "body": "@Test\n\tpublic final void testEqualsWithDifferentStopBits() {\n\t\t// Setup the resources for the test.\n\t\tSerialPortParameters parameters1 = new SerialPortParameters(9600, 8, 1, 0, 0);\n\t\tSerialPortParameters parameters2 = new SerialPortParameters(9600, 8, 2, 0, 0);\n\t\t\n\t\t// Call the method unde...
{ "fields": [ { "declarator": "HASH_SEED = 23", "modifier": "private static final", "original_string": "private static final int HASH_SEED = 23;", "type": "int", "var_name": "HASH_SEED" }, { "declarator": "baudrate", "modifier": "public final", "original_str...
{ "body": "@Override\n\tpublic boolean equals(Object obj) {\n\t\tif (obj instanceof SerialPortParameters)\n\t\t\treturn ((SerialPortParameters)obj).baudrate == baudrate \n\t\t\t\t&& ((SerialPortParameters)obj).dataBits == dataBits \n\t\t\t\t&& ((SerialPortParameters)obj).stopBits == stopBits\n\t\t\t\t&& ((SerialPortP...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_140
{ "fields": [ { "declarator": "exception = ExpectedException.none()", "modifier": "@Rule\n\tpublic", "original_string": "@Rule\n\tpublic ExpectedException exception = ExpectedException.none();", "type": "ExpectedException", "var_name": "exception" } ], "file": "library/src/te...
{ "body": "@Test\n\tpublic final void testIsBroadcastWithNon16BitAndNon64BitBroadcastDestinationAddress() {\n\t\t// Setup the resources for the test.\n\t\tint frameID = 0x65;\n\t\tXBee64BitAddress dest64Addr = new XBee64BitAddress(\"0013A2004032D9AB\");\n\t\tXBee16BitAddress dest16Addr = new XBee16BitAddress(\"D817\"...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 20", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 20;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "destAddress64", "mo...
{ "body": "@Override\n\tpublic boolean isBroadcast() {\n\t\tif (get64BitDestinationAddress().equals(XBee64BitAddress.BROADCAST_ADDRESS) \n\t\t\t\t|| get16BitDestinationAddress().equals(XBee16BitAddress.BROADCAST_ADDRESS))\n\t\t\treturn true;\n\t\treturn false;\n\t}", "class_method_signature": "ExplicitAddressingPac...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_455
{ "fields": [ { "declarator": "exception = ExpectedException.none()", "modifier": "@Rule\n\tpublic", "original_string": "@Rule\n\tpublic ExpectedException exception = ExpectedException.none();", "type": "ExpectedException", "var_name": "exception" } ], "file": "library/src/te...
{ "body": "@Test\n\tpublic final void testCreatePacketPayloadShorterThanNeeded() {\n\t\t// Setup the resources for the test.\n\t\tint frameType = APIFrameType.TX_STATUS.getValue();\n\t\tint frameID = 0xE7;\n\t\t\n\t\tbyte[] payload = new byte[2];\n\t\tpayload[0] = (byte)frameType;\n\t\tpayload[1] = (byte)frameID;\n\t...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 3", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 3;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "transmitStatus", "mod...
{ "body": "public static TXStatusPacket createPacket(byte[] payload) {\n\t\tif (payload == null)\n\t\t\tthrow new NullPointerException(\"TX Status packet payload cannot be null.\");\n\t\t\n\t\t// 1 (Frame type) + 1 (frame ID) + 1 (status)\n\t\tif (payload.length < MIN_API_PAYLOAD_LENGTH)\n\t\t\tthrow new IllegalArgum...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_681
{ "fields": [ { "declarator": "exception = ExpectedException.none()", "modifier": "@Rule\n\tpublic", "original_string": "@Rule\n\tpublic ExpectedException exception = ExpectedException.none();", "type": "ExpectedException", "var_name": "exception" } ], "file": "library/src/te...
{ "body": "@Test\n\tpublic final void testReadBytesMoreBytesThanAvailable() {\n\t\t// Setup the resources for the test.\n\t\tbyte[] contents = new byte[]{0x00, 0x01, 0x02, 0x03, 0x04};\n\t\tByteArrayInputStream in = new ByteArrayInputStream(contents);\n\t\t\n\t\t// Call the method under test.\n\t\tbyte[] result = Byt...
{ "fields": [], "file": "library/src/main/java/com/digi/xbee/api/utils/ByteUtils.java", "identifier": "ByteUtils", "interfaces": "", "methods": [ { "class_method_signature": "ByteUtils.readBytes(int numBytes, ByteArrayInputStream inputStream)", "constructor": false, "full_signature": "pu...
{ "body": "public static byte[] readBytes(int numBytes, ByteArrayInputStream inputStream) {\n\t\tif (inputStream == null)\n\t\t\tthrow new NullPointerException(\"Input stream cannot be null.\");\n\t\tif (numBytes < 0)\n\t\t\tthrow new IllegalArgumentException(\"Number of bytes to read must be equal or greater than 0....
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_394
{ "fields": [ { "declarator": "IP_ADDRESS = \"10.10.11.12\"", "modifier": "private static final", "original_string": "private static final String IP_ADDRESS = \"10.10.11.12\";", "type": "String", "var_name": "IP_ADDRESS" }, { "declarator": "frameType = APIFrameType.REMO...
{ "body": "@Test\n\tpublic final void testGetAPIPacketParametersATCommandParameterNotString() {\n\t\t// Setup the resources for the test.\n\t\tRemoteATCommandResponseWifiPacket packet = new RemoteATCommandResponseWifiPacket(frameID, sourceAddress, command, status, commandValue);\n\n\t\t// Call the method under test.\...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 13", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 13;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "ERROR_PAYLOAD_NULL = \"Re...
{ "body": "@Override\n\tpublic LinkedHashMap<String, String> getAPIPacketParameters() {\n\t\tLinkedHashMap<String, String> parameters = new LinkedHashMap<String, String>();\n\t\tparameters.put(\"Source address\", \"00 00 00 00 \" + HexUtils.prettyHexString(HexUtils.byteArrayToHexString(sourceAddress.getAddress())) + ...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_21
{ "fields": [ { "declarator": "exception = ExpectedException.none()", "modifier": "@Rule\n\tpublic", "original_string": "@Rule\n\tpublic ExpectedException exception = ExpectedException.none();", "type": "ExpectedException", "var_name": "exception" } ], "file": "library/src/te...
{ "body": "@Test\n\tpublic final void testCreatePacketNullPayload() {\n\t\t// Setup the resources for the test.\n\t\tbyte[] payload = null;\n\t\texception.expect(NullPointerException.class);\n\t\texception.expectMessage(is(equalTo(\"Transmit packet payload cannot be null.\")));\n\t\t\n\t\t// Call the method under tes...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 14", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 14;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "destAddress64", "mo...
{ "body": "public static TransmitPacket createPacket(byte[] payload) {\n\t\tif (payload == null)\n\t\t\tthrow new NullPointerException(\"Transmit packet payload cannot be null.\");\n\t\t\n\t\t// 1 (Frame type) + 1 (frame ID) + 8 (64-bit address) + 2 (16-bit address) + 1 (broadcast radious) + 1 (options)\n\t\tif (payl...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_117
{ "fields": [ { "declarator": "exception = ExpectedException.none()", "modifier": "@Rule\n\tpublic", "original_string": "@Rule\n\tpublic ExpectedException exception = ExpectedException.none();", "type": "ExpectedException", "var_name": "exception" } ], "file": "library/src/te...
{ "body": "@Test\n\tpublic final void testIsBroadcastWith16BitBroadcastAndNon64BitBroadcastDestinationAddress() {\n\t\t// Setup the resources for the test.\n\t\tint frameID = 0x10;\n\t\tXBee64BitAddress dest64Addr = new XBee64BitAddress(\"0013A2004032D9AB\");\n\t\tXBee16BitAddress dest16Addr = new XBee16BitAddress(\"...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 15", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 15;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "destAddress64", "mo...
{ "body": "@Override\n\tpublic boolean isBroadcast() {\n\t\treturn get64bitDestinationAddress().equals(XBee64BitAddress.BROADCAST_ADDRESS) \n\t\t\t\t|| get16bitDestinationAddress().equals(XBee16BitAddress.BROADCAST_ADDRESS);\n\t}", "class_method_signature": "RemoteATCommandPacket.isBroadcast()", "constructor": fa...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_547
{ "fields": [ { "declarator": "RECEIVED_BUFFER = \"Hello, this is the received data\".getBytes()", "modifier": "private static final", "original_string": "private static final byte[] RECEIVED_BUFFER = \"Hello, this is the received data\".getBytes();", "type": "byte[]", "var_name": "R...
{ "body": "@Test\n\tpublic final void testReadDataByteArrayInputStreamNull() throws IOException {\n\t\t// Setup the resources for the test.\n\t\tTestAbstractSerialPort port = Mockito.spy(new TestAbstractSerialPort(\"COM1\", 9600));\n\t\tmockInputStream = null;\n\t\tbyte[] data = new byte[0];\n\t\t\n\t\t// Call the me...
{ "fields": [ { "declarator": "DEFAULT_PORT_TIMEOUT = 10", "modifier": "public static final", "original_string": "public static final int DEFAULT_PORT_TIMEOUT = 10;", "type": "int", "var_name": "DEFAULT_PORT_TIMEOUT" }, { "declarator": "DEFAULT_DATA_BITS = 8", "mo...
{ "body": "@Override\n\tpublic int readData(byte[] data) throws IOException {\n\t\tif (data == null)\n\t\t\tthrow new NullPointerException(\"Buffer cannot be null.\");\n\t\t\n\t\tint readBytes = 0;\n\t\tif (getInputStream() != null)\n\t\t\treadBytes = getInputStream().read(data);\n\t\treturn readBytes;\n\t}", "clas...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_814
{ "fields": [ { "declarator": "INVALID_BYTE_ARRAY = new byte[]{0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08}", "modifier": "private final static", "original_string": "private final static byte[] INVALID_BYTE_ARRAY = new byte[]{0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08};", ...
{ "body": "@Test\n\tpublic final void testEqualsWithDifferentIMEI() {\n\t\t// Setup the resources for the test.\n\t\tXBeeIMEIAddress imei1 = new XBeeIMEIAddress(\"1234\");\n\t\tXBeeIMEIAddress imei2 = new XBeeIMEIAddress(\"5678\");\n\t\t\n\t\t// Call the method under test.\n\t\tboolean areEqual1 = imei1.equals(imei2)...
{ "fields": [ { "declarator": "ERROR_IMEI_NULL = \"IMEI address cannot be null.\"", "modifier": "private static final", "original_string": "private static final String ERROR_IMEI_NULL = \"IMEI address cannot be null.\";", "type": "String", "var_name": "ERROR_IMEI_NULL" }, { ...
{ "body": "@Override\n\tpublic boolean equals(Object obj) {\n\t\tif (obj == null)\n\t\t\treturn false;\n\t\tif (!(obj instanceof XBeeIMEIAddress))\n\t\t\treturn false;\n\t\tXBeeIMEIAddress addr = (XBeeIMEIAddress)obj;\n\t\treturn addr.getValue().equals(getValue());\n\t}", "class_method_signature": "XBeeIMEIAddress....
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_402
{ "fields": [ { "declarator": "exception = ExpectedException.none()", "modifier": "@Rule\n\tpublic", "original_string": "@Rule\n\tpublic ExpectedException exception = ExpectedException.none();", "type": "ExpectedException", "var_name": "exception" } ], "file": "library/src/te...
{ "body": "@Test\n\tpublic final void testIsBroadcastWithNonBroadcastOption() {\n\t\t// Setup the resources for the test.\n\t\tXBee64BitAddress source64Addr = new XBee64BitAddress(\"0013A2004032D9AB\");\n\t\tint rssi = 75;\n\t\tint options = 0x18;\n\t\tbyte[] receivedData = new byte[]{0x68, 0x6F, 0x6C, 0x61};\n\t\tRX...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 11", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 11;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "sourceAddress64", "...
{ "body": "@Override\n\tpublic boolean isBroadcast() {\n\t\treturn ByteUtils.isBitEnabled(getReceiveOptions(), 1)\n\t\t\t\t|| ByteUtils.isBitEnabled(getReceiveOptions(), 2);\n\t}", "class_method_signature": "RX64Packet.isBroadcast()", "constructor": false, "full_signature": "@Override public boolean isBroadcast...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_697
{ "fields": [ { "declarator": "exception = ExpectedException.none()", "modifier": "@Rule\n\tpublic", "original_string": "@Rule\n\tpublic ExpectedException exception = ExpectedException.none();", "type": "ExpectedException", "var_name": "exception" } ], "file": "library/src/te...
{ "body": "@Test\n\tpublic final void testByteArrayToIntEmptyArray() {\n\t\t// Setup the resources for the test.\n\t\tbyte[] byteArray = new byte[0];\n\t\tint expectedResult = 0;\n\t\t\n\t\t// Call the method under test.\n\t\tint result = ByteUtils.byteArrayToInt(byteArray);\n\t\t\n\t\t// Verify the result.\n\t\tasse...
{ "fields": [], "file": "library/src/main/java/com/digi/xbee/api/utils/ByteUtils.java", "identifier": "ByteUtils", "interfaces": "", "methods": [ { "class_method_signature": "ByteUtils.readBytes(int numBytes, ByteArrayInputStream inputStream)", "constructor": false, "full_signature": "pu...
{ "body": "public static int byteArrayToInt(byte[] byteArray) {\n\t\tif (byteArray == null)\n\t\t\tthrow new NullPointerException(\"Byte array cannot be null.\");\n\t\t\n\t\tif (byteArray.length == 0)\n\t\t\treturn 0;\n\t\t\n\t\tbyte[] values = byteArray;\n\t\tif (byteArray.length < 4) {\n\t\t\tvalues = new byte[4];\...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_37
{ "fields": [ { "declarator": "exception = ExpectedException.none()", "modifier": "@Rule\n\tpublic", "original_string": "@Rule\n\tpublic ExpectedException exception = ExpectedException.none();", "type": "ExpectedException", "var_name": "exception" } ], "file": "library/src/te...
{ "body": "@Test\n\tpublic final void testGetAPIPacketParameters() {\n\t\t// Setup the resources for the test.\n\t\tModemStatusEvent modemStatusEvent = ModemStatusEvent.STATUS_JOINED_NETWORK;\n\t\tModemStatusPacket packet = new ModemStatusPacket(modemStatusEvent);\n\t\t\n\t\tString expectedModemStatus = HexUtils.inte...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 2", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 2;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "modemStatusEvent", "m...
{ "body": "@Override\n\tpublic LinkedHashMap<String, String> getAPIPacketParameters() {\n\t\tLinkedHashMap<String, String> parameters = new LinkedHashMap<String, String>();\n\t\tparameters.put(\"Status\", HexUtils.prettyHexString(HexUtils.integerToHexString(modemStatusEvent.getId(), 1)) + \" (\" + modemStatusEvent.ge...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_228
{ "fields": [ { "declarator": "IPV6_SRC_ADDRESS = \"FDB3:0001:0002:0000:0004:0005:0006:0007\"", "modifier": "private static final", "original_string": "private static final String IPV6_SRC_ADDRESS = \"FDB3:0001:0002:0000:0004:0005:0006:0007\";", "type": "String", "var_name": "IPV6_SR...
{ "body": "@Test\n\tpublic final void testCreatePacketPayloadNotIncludingFrameType() {\n\t\t// Set up the resources for the test.\n\t\tbyte[] payload = new byte[38 + data.length];\n\t\tSystem.arraycopy(destAddress.getAddress(), 0, payload, 0, destAddress.getAddress().length);\n\t\tSystem.arraycopy(sourceAddress.getAd...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 39", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 39;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "ERROR_PAYLOAD_NULL = \"RX...
{ "body": "public static RXIPv6Packet createPacket(byte[] payload) {\n\t\tif (payload == null)\n\t\t\tthrow new NullPointerException(ERROR_PAYLOAD_NULL);\n\n\t\tif (payload.length < MIN_API_PAYLOAD_LENGTH)\n\t\t\tthrow new IllegalArgumentException(ERROR_INCOMPLETE_PACKET);\n\n\t\tif ((payload[0] & 0xFF) != APIFrameTy...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_678
{ "fields": [ { "declarator": "exception = ExpectedException.none()", "modifier": "@Rule\n\tpublic", "original_string": "@Rule\n\tpublic ExpectedException exception = ExpectedException.none();", "type": "ExpectedException", "var_name": "exception" } ], "file": "library/src/te...
{ "body": "@Test\n\tpublic final void testReadBytesNullInputStream() {\n\t\t// Setup the resources for the test.\n\t\tByteArrayInputStream in = null;\n\t\texception.expect(NullPointerException.class);\n\t\texception.expectMessage(is(equalTo(\"Input stream cannot be null.\")));\n\t\t\n\t\t// Call the method under test...
{ "fields": [], "file": "library/src/main/java/com/digi/xbee/api/utils/ByteUtils.java", "identifier": "ByteUtils", "interfaces": "", "methods": [ { "class_method_signature": "ByteUtils.readBytes(int numBytes, ByteArrayInputStream inputStream)", "constructor": false, "full_signature": "pu...
{ "body": "public static byte[] readBytes(int numBytes, ByteArrayInputStream inputStream) {\n\t\tif (inputStream == null)\n\t\t\tthrow new NullPointerException(\"Input stream cannot be null.\");\n\t\tif (numBytes < 0)\n\t\t\tthrow new IllegalArgumentException(\"Number of bytes to read must be equal or greater than 0....
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_382
{ "fields": [ { "declarator": "IP_ADDRESS = \"10.10.11.12\"", "modifier": "private static final", "original_string": "private static final String IP_ADDRESS = \"10.10.11.12\";", "type": "String", "var_name": "IP_ADDRESS" }, { "declarator": "frameType = APIFrameType.REMO...
{ "body": "@Test\n\tpublic final void testCreatePacketPayloadNotIncludingFrameType() {\n\t\t// Setup the resources for the test.\n\t\tbyte[] payload = new byte[12 + parameter.length];\n\t\tpayload[0] = (byte)frameID;\n\t\tSystem.arraycopy(new byte[]{0x00, 0x00, 0x00, 0x00}, 0, payload, 1, 4);\n\t\tSystem.arraycopy(de...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 13", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 13;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "ERROR_PAYLOAD_NULL = \"Re...
{ "body": "public static RemoteATCommandWifiPacket createPacket(byte[] payload) {\n\t\tif (payload == null)\n\t\t\tthrow new NullPointerException(ERROR_PAYLOAD_NULL);\n\n\t\tif (payload.length < MIN_API_PAYLOAD_LENGTH)\n\t\t\tthrow new IllegalArgumentException(ERROR_INCOMPLETE_PACKET);\n\n\t\tif ((payload[0] & 0xFF) ...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_802
{ "fields": [ { "declarator": "INVALID_BYTE_ARRAY = new byte[]{0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09}", "modifier": "private final static", "original_string": "private final static byte[] INVALID_BYTE_ARRAY = new byte[]{0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0...
{ "body": "@Test\n\tpublic final void testEqualsIsTransitive() {\n\t\t// Setup the resources for the test.\n\t\tXBee64BitAddress addr1 = new XBee64BitAddress(\"0x0013A20040123456\");\n\t\tXBee64BitAddress addr2 = new XBee64BitAddress(\"0x0013A20040123456\");\n\t\tXBee64BitAddress addr3 = new XBee64BitAddress(\"0x0013...
{ "fields": [ { "declarator": "COORDINATOR_ADDRESS = new XBee64BitAddress(\"0000\")", "modifier": "public static final", "original_string": "public static final XBee64BitAddress COORDINATOR_ADDRESS = new XBee64BitAddress(\"0000\");", "type": "XBee64BitAddress", "var_name": "COORDINAT...
{ "body": "@Override\n\tpublic boolean equals(Object obj) {\n\t\tif (!(obj instanceof XBee64BitAddress))\n\t\t\treturn false;\n\t\tXBee64BitAddress addr = (XBee64BitAddress)obj;\n\t\treturn Arrays.equals(addr.getValue(), getValue());\n\t}", "class_method_signature": "XBee64BitAddress.equals(Object obj)", "constru...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_551
{ "fields": [ { "declarator": "RECEIVED_BUFFER = \"Hello, this is the received data\".getBytes()", "modifier": "private static final", "original_string": "private static final byte[] RECEIVED_BUFFER = \"Hello, this is the received data\".getBytes();", "type": "byte[]", "var_name": "R...
{ "body": "@Test\n\tpublic final void testReadDataCompleteNegativeOffset() throws IOException {\n\t\t// Setup the resources for the test.\n\t\tTestAbstractSerialPort port = Mockito.spy(new TestAbstractSerialPort(\"COM1\", 9600));\n\t\tbyte[] data = new byte[0];\n\t\tint offset = -5;\n\t\tint length = 0;\n\t\t\n\t\tex...
{ "fields": [ { "declarator": "DEFAULT_PORT_TIMEOUT = 10", "modifier": "public static final", "original_string": "public static final int DEFAULT_PORT_TIMEOUT = 10;", "type": "int", "var_name": "DEFAULT_PORT_TIMEOUT" }, { "declarator": "DEFAULT_DATA_BITS = 8", "mo...
{ "body": "@Override\n\tpublic int readData(byte[] data) throws IOException {\n\t\tif (data == null)\n\t\t\tthrow new NullPointerException(\"Buffer cannot be null.\");\n\t\t\n\t\tint readBytes = 0;\n\t\tif (getInputStream() != null)\n\t\t\treadBytes = getInputStream().read(data);\n\t\treturn readBytes;\n\t}", "clas...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_101
{ "fields": [ { "declarator": "exception = ExpectedException.none()", "modifier": "@Rule\n\tpublic", "original_string": "@Rule\n\tpublic ExpectedException exception = ExpectedException.none();", "type": "ExpectedException", "var_name": "exception" } ], "file": "library/src/te...
{ "body": "@Test\n\tpublic final void testGetAPIPacketParametersReceivedDataNotNull() {\n\t\t// Setup the resources for the test.\n\t\tXBee64BitAddress source64Addr = new XBee64BitAddress(\"0013A2004032D9AB\");\n\t\tXBee16BitAddress source16Addr = new XBee16BitAddress(\"D817\");\n\t\tint options = 40;\n\t\tbyte[] rec...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 12", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 12;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "sourceAddress64", "...
{ "body": "@Override\n\tpublic LinkedHashMap<String, String> getAPIPacketParameters() {\n\t\tLinkedHashMap<String, String> parameters = new LinkedHashMap<String, String>();\n\t\tparameters.put(\"64-bit source address\", HexUtils.prettyHexString(sourceAddress64.toString()));\n\t\tparameters.put(\"16-bit source address...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }
21871478_414
{ "fields": [ { "declarator": "exception = ExpectedException.none()", "modifier": "@Rule\n\tpublic", "original_string": "@Rule\n\tpublic ExpectedException exception = ExpectedException.none();", "type": "ExpectedException", "var_name": "exception" } ], "file": "library/src/te...
{ "body": "@Test\n\tpublic final void testIsBroadcastWithNonBroadcastOption() {\n\t\t// Setup the resources for the test.\n\t\tXBee16BitAddress source16Addr = new XBee16BitAddress(\"D817\");\n\t\tint rssi = 75;\n\t\tint options = 0x00;\n\t\tbyte[] receivedData = new byte[]{(byte)0xFF, (byte)0xFF, (byte)0xFF, (byte)0x...
{ "fields": [ { "declarator": "MIN_API_PAYLOAD_LENGTH = 5", "modifier": "private static final", "original_string": "private static final int MIN_API_PAYLOAD_LENGTH = 5;", "type": "int", "var_name": "MIN_API_PAYLOAD_LENGTH" }, { "declarator": "sourceAddress16", "mo...
{ "body": "@Override\n\tpublic boolean isBroadcast() {\n\t\treturn ByteUtils.isBitEnabled(getReceiveOptions(), 1)\n\t\t\t\t|| ByteUtils.isBitEnabled(getReceiveOptions(), 2);\n\t}", "class_method_signature": "RX16IOPacket.isBroadcast()", "constructor": false, "full_signature": "@Override public boolean isBroadca...
{ "created": null, "fork": null, "fork_count": 54, "is_fork": false, "language": "Java", "license": "licensed", "repo_id": 21871478, "size": 3156, "stargazer_count": 76, "stars": null, "updates": null, "url": "https://github.com/digidotcom/xbee-java" }