Commit 7d97a378 7d97a378744f770f036cd8f9689d52ac1853c368 by root

save

1 parent fdc560af
Showing 33 changed files with 312 additions and 11 deletions
3a7c36b54c3b47d30241a72b0c0bb2e0
\ No newline at end of file
3ce1dbb50c1859a996ad64af891ae9d1fb39d67e
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>
<groupId>org.emercit</groupId>
<artifactId>projecttools</artifactId>
<version>1.5</version>
</project>
54d40448e9dd031e0f85ac5089bd7378
\ No newline at end of file
0ed3336ff2e554a5b56cb10199abaa15ca7904c7
\ No newline at end of file
......@@ -3,10 +3,11 @@
<groupId>org.emercit</groupId>
<artifactId>projecttools</artifactId>
<versioning>
<release>1.0</release>
<release>1.5</release>
<versions>
<version>1.0</version>
<version>1.5</version>
</versions>
<lastUpdated>20150727174710</lastUpdated>
<lastUpdated>20150727175307</lastUpdated>
</versioning>
</metadata>
......
2dd1370d0a69ae3d68f433b9fb487aee
\ No newline at end of file
b260825c3bfcf4adbc4c55f14b06a533
\ No newline at end of file
......
d9bae35fba7e4396dba36201545becfff6d670d0
\ No newline at end of file
42f45f1bfe5327569975623e348e4d84480f536b
\ No newline at end of file
......
27d71720f5e8b6a7c18f8aec6cc0b7f0
\ No newline at end of file
7a44dae6995fedbafc586ff3552cb62faf989201
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>
<groupId>org.emercit</groupId>
<artifactId>xmldbmanager</artifactId>
<version>1.5</version>
</project>
1b8cbe07fbb2f057541b41b2e4fc9d7a
\ No newline at end of file
ed352e58e6901ec42e9233fb21e10878b971d757
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<metadata>
<groupId>org.emercit</groupId>
<artifactId>xmldbmanager</artifactId>
<versioning>
<release>1.5</release>
<versions>
<version>1.5</version>
</versions>
<lastUpdated>20150727175435</lastUpdated>
</versioning>
</metadata>
9d9bd8eeebf7c32026cb5f377d34e6bd
\ No newline at end of file
019beb72ec1a4032ad5599472f00603603b9651b
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" output="target/classes" path="src/main/java">
<attributes>
<attribute name="optional" value="true"/>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="src" output="target/test-classes" path="src/test/java">
<attributes>
<attribute name="optional" value="true"/>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="output" path="target/classes"/>
</classpath>
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>GSMManager</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.m2e.core.maven2Builder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
<nature>org.eclipse.m2e.core.maven2Nature</nature>
</natures>
</projectDescription>
eclipse.preferences.version=1
encoding//src/main/java=UTF-8
encoding//src/test/java=UTF-8
encoding/<project>=UTF-8
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
org.eclipse.jdt.core.compiler.compliance=1.7
org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
org.eclipse.jdt.core.compiler.source=1.7
activeProfiles=
eclipse.preferences.version=1
resolveWorkspaceProjects=true
version=1
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.emercit</groupId>
<artifactId>GsmModemManager</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>GsmModemManager</name>
<url>http://maven.apache.org</url>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.7</source>
<target>1.7</target>
<showDeprecation>true</showDeprecation>
<showWarnings>true</showWarnings>
<executable>${env.JAVA_HOME_7}/bin/javac</executable>
<fork>true</fork>
</configuration>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.emercit</groupId>
<artifactId>xmldbmanager</artifactId>
<version>1.5</version>
</dependency>
<dependency>
<groupId>org.emercit</groupId>
<artifactId>projecttools</artifactId>
<version>1.5</version>
</dependency>
</dependencies>
<repositories>
<!--other repositories if any-->
<repository>
<id>project.local</id>
<name>project</name>
<url>file:/root/git/hardwareconfig/DevTools/repo</url>
</repository>
</repositories>
</project>
package org.emercit.gsmmanager;
import org.emercit.gsmmanager.service.Gsm;
public class App
{
public static void main( String[] args )
{
Gsm gsm=new Gsm();
gsm.init();
}
}
package org.emercit.gsmmanager.model;
import java.io.Serializable;
import java.util.Vector;
public class GSMBean implements Serializable {
private static final long serialVersionUID = 1L;
private String operator;
public GSMBean() {
}
public void setOperator(String value) {
this.operator=value;
}
public String getOperator() {
return operator;
}
}
package org.emercit.gsmmanager.service;
import org.emercit.gsmmanager.model.GSMBean;
import org.emercit.xmldbmanager.service.Db;
import org.emercit.projecttools.constants.Paths;
public class Gsm implements IGsm {
private Db db=new Db(Paths.BEAN_GSM);
private GSMBean m;
public GSMBean get() {
return (GSMBean)db.select();
}
public boolean set(GSMBean m) {
return db.create(m);
}
/*
* Создание нового файла с параметрами - defaults
* @see org.emercit.gsmmanager.service.IGsm#init()
*/
public void init() {
m=new GSMBean();
m.setOperator("megafon");
db.create(m);
}
}
package org.emercit.gsmmanager.service;
import org.emercit.gsmmanager.model.GSMBean;
public interface IGsm {
public GSMBean get();
public boolean set(GSMBean m);
public void init();
}
package org.emercit.GsmModemManager;
import junit.framework.Test;
import junit.framework.TestCase;
import junit.framework.TestSuite;
/**
* Unit test for simple App.
*/
public class AppTest
extends TestCase
{
/**
* Create the test case
*
* @param testName name of the test case
*/
public AppTest( String testName )
{
super( testName );
}
/**
* @return the suite of tests being tested
*/
public static Test suite()
{
return new TestSuite( AppTest.class );
}
/**
* Rigourous Test :-)
*/
public void testApp()
{
assertTrue( true );
}
}
......@@ -12,12 +12,12 @@
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7">
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
......
......@@ -48,7 +48,7 @@
<dependency>
<groupId>org.emercit</groupId>
<artifactId>projecttools</artifactId>
<version>1.0</version>
<version>1.5</version>
</dependency>
</dependencies>
......
......@@ -10,11 +10,9 @@ import java.io.FileOutputStream;
import org.emercit.projecttools.constants.Paths;
public class Db implements IDb {
private String pathfile=null;
public Db(String path) {
this.pathfile=path;
}
......@@ -24,7 +22,7 @@ public class Db implements IDb {
* @see org.emercit.xmldbmanager.service.IDb#create(java.lang.Object)
*/
public boolean create(Object o) {
boolean result=true;
try {
FileOutputStream fos = new FileOutputStream(pathfile);
......