Skip to content

Commit

Permalink
FirstCommit
Browse files Browse the repository at this point in the history
  • Loading branch information
Manojkumar Bhosale committed Jan 2, 2019
0 parents commit 57394b9
Show file tree
Hide file tree
Showing 122 changed files with 5,386 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .classpath
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry including="**/*.java" kind="src" output="target/classes" path="src">
<attributes>
<attribute name="optional" value="true"/>
<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.8">
<attributes>
<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="output" path="target/classes"/>
</classpath>
23 changes: 23 additions & 0 deletions .project
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>MAutomaton</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.m2e.core.maven2Nature</nature>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
</projectDescription>
12 changes: 12 additions & 0 deletions .settings/org.eclipse.jdt.core.prefs
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
org.eclipse.jdt.core.compiler.compliance=1.8
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
org.eclipse.jdt.core.compiler.source=1.8
4 changes: 4 additions & 0 deletions .settings/org.eclipse.m2e.core.prefs
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
activeProfiles=
eclipse.preferences.version=1
resolveWorkspaceProjects=true
version=1
Binary file not shown.
Binary file not shown.
Binary file added bin/com/psl/automation/main/BigTextField$1.class
Binary file not shown.
Binary file added bin/com/psl/automation/main/BigTextField.class
Binary file not shown.
Binary file added bin/com/psl/automation/main/FileChooserDemo$1.class
Binary file not shown.
Binary file added bin/com/psl/automation/main/FileChooserDemo.class
Binary file not shown.
Binary file added bin/com/psl/automation/main/Interval.class
Binary file not shown.
Binary file added bin/com/psl/automation/main/MainGui$1.class
Binary file not shown.
Binary file added bin/com/psl/automation/main/MainGui.class
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added bin/com/psl/swingexample/DigitalWatch.class
Binary file not shown.
Binary file added bin/com/psl/swingexample/DisplayGraphics.class
Binary file not shown.
Binary file added bin/com/psl/swingexample/FirstSwingExample.class
Binary file not shown.
Binary file added bin/com/psl/swingexample/JIFrameDemo$1.class
Binary file not shown.
Binary file added bin/com/psl/swingexample/JIFrameDemo$2.class
Binary file not shown.
Binary file added bin/com/psl/swingexample/JIFrameDemo.class
Binary file not shown.
Binary file added bin/com/psl/swingexample/MainScreen.class
Binary file not shown.
Binary file added bin/com/psl/swingexample/MyProgress.class
Binary file not shown.
Binary file added bin/com/psl/swingexample/Notepad.class
Binary file not shown.
Binary file added bin/com/psl/swingexample/OpenMenu.class
Binary file not shown.
Binary file added bin/hsutils/BAMParser.class
Binary file not shown.
Binary file added bin/hsutils/BamSorter.class
Binary file not shown.
Binary file added bin/hsutils/TestAl.class
Binary file not shown.
Binary file added bin/liftoverutils/BedInterval.class
Binary file not shown.
Binary file added bin/liftoverutils/Chain.class
Binary file not shown.
Binary file added bin/liftoverutils/ChainException.class
Binary file not shown.
Binary file added bin/liftoverutils/Interval.class
Binary file not shown.
Binary file added bin/liftoverutils/IntervalNode.class
Binary file not shown.
Binary file added bin/liftoverutils/IntervalTree.class
Binary file not shown.
Binary file added bin/liftoverutils/LiftOverDriver.class
Binary file not shown.
11 changes: 11 additions & 0 deletions bin/log4j.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Define the root logger with appender file
log = c:/gatKAutomator/log4j
log4j.rootLogger = DEBUG, FILE

# Define the file appender
log4j.appender.FILE=org.apache.log4j.FileAppender
log4j.appender.FILE.File=${log}/log.out

# Define the layout for file appender
log4j.appender.FILE.layout=org.apache.log4j.PatternLayout
log4j.appender.FILE.layout.conversionPattern=%m%n
Binary file added bin/qcutils/QCCompareResults.class
Binary file not shown.
Binary file added bin/qcutils/QCMetricsCompare.class
Binary file not shown.
Binary file added bin/vcfutils/CompareUtils.class
Binary file not shown.
Binary file added bin/vcfutils/ComparisonResult.class
Binary file not shown.
Binary file added bin/vcfutils/TestVCFreader.class
Binary file not shown.
Binary file added bin/vcfutils/TsTvStatistics$1.class
Binary file not shown.
Binary file added bin/vcfutils/TsTvStatistics$2.class
Binary file not shown.
Binary file added bin/vcfutils/TsTvStatistics.class
Binary file not shown.
Binary file added bin/vcfutils/VCFUtils.class
Binary file not shown.
Binary file added bin/vcfutils/VCFrecord.class
Binary file not shown.
Binary file added bin/vcfutils/VariantExceptions.class
Binary file not shown.
Binary file added bin/vcfutils/VariantTypes.class
Binary file not shown.
Empty file added comparisonResults/common.vcf
Empty file.
Empty file added comparisonResults/delNew.vcf
Empty file.
Empty file added comparisonResults/delOld.vcf
Empty file.
Empty file added comparisonResults/insNew.vcf
Empty file.
Empty file added comparisonResults/insOld.vcf
Empty file.
Empty file added comparisonResults/snpNew.vcf
Empty file.
Empty file added comparisonResults/snpOld.vcf
Empty file.
43 changes: 43 additions & 0 deletions dependency-reduced-pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
<?xml version="1.0" encoding="UTF-8"?>
<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/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>Automaton</groupId>
<artifactId>MAutomaton</artifactId>
<version>0.0.2-SNAPSHOT</version>
<build>
<sourceDirectory>src</sourceDirectory>
<resources>
<resource>
<directory>src</directory>
<excludes>
<exclude>**/*.java</exclude>
</excludes>
</resource>
</resources>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.7.0</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
<plugin>
<artifactId>maven-clean-plugin</artifactId>
<version>2.5</version>
</plugin>
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<version>3.1.0</version>
<configuration>
<archive>
<manifest>
<mainClass>com.psl.automation.main.MainGui</mainClass>
</manifest>
</archive>
</configuration>
</plugin>
</plugins>
</build>
</project>
90 changes: 90 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
<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>Automaton</groupId>
<artifactId>MAutomaton</artifactId>
<version>0.0.2-SNAPSHOT</version>


<dependencies>
<!-- https://mvnrepository.com/artifact/org.apache.httpcomponents/httpcore -->
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpcore</artifactId>
<version>4.4.6</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.apache.httpcomponents/httpclient -->
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>4.2.5</version>
</dependency>


<!-- https://mvnrepository.com/artifact/org.apache.httpcomponents/httpmime -->
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpmime</artifactId>
<version>4.2.5</version>
</dependency>

<!-- https://mvnrepository.com/artifact/com.github.samtools/htsjdk -->
<dependency>
<groupId>com.github.samtools</groupId>
<artifactId>htsjdk</artifactId>
<version>2.17.0</version>
</dependency>
<!-- https://mvnrepository.com/artifact/log4j/log4j -->
<dependency>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
<version>1.2.17</version>
</dependency>


</dependencies>


<build>
<sourceDirectory>src</sourceDirectory>
<resources>
<resource>
<directory>src</directory>
<excludes>
<exclude>**/*.java</exclude>
</excludes>
</resource>
</resources>



<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.7.0</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-clean-plugin</artifactId>
<version>2.5</version>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>3.1.0</version>
<configuration>
<archive>
<manifest>
<mainClass>com.psl.automation.main.MainGui</mainClass>
</manifest>
</archive>
</configuration>
</plugin>
</plugins>
</build>
</project>
16 changes: 16 additions & 0 deletions src/com/psl/automation/annotation/Driver.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
package com.psl.automation.annotation;

import java.io.File;

public class Driver {

public static void main(String[] args) {
VariationReporter vr = new VariationReporter();
try {
System.out.println(vr.analyze(9606, "GCF_000001405.25", "", new File("C:\\Users\\manojkumar_bhosale\\Desktop\\TestVariationreporter\\vcf.vcf")));
} catch (Exception e) {
System.out.println(e);
}
}

}
50 changes: 50 additions & 0 deletions src/com/psl/automation/annotation/VariationReporter.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
package com.psl.automation.annotation;

import java.io.File;

import org.apache.http.client.HttpClient;
import org.apache.http.client.ResponseHandler;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.entity.mime.MultipartEntity;
import org.apache.http.entity.mime.content.FileBody;
import org.apache.http.entity.mime.content.StringBody;
import org.apache.http.impl.client.BasicResponseHandler;
import org.apache.http.impl.client.DefaultHttpClient;

public class VariationReporter {

private String postUrl = "https://www.ncbi.nlm.nih.gov/projects/SNP/VariantAnalyzer/var_rep.cgi"; //post url

public String analyze(int organism, String src_assembly, String annot1, File annot) throws Exception {
String result = null;
HttpClient httpClient = new DefaultHttpClient(); //user agent
//httpClient.getParams().setParameter(CoreConnectionPNames.CONNECTION_TIMEOUT, 30000); //user agent timeout must be at least 30 sec.

HttpPost httpPost = new HttpPost(postUrl);
MultipartEntity multiPartEntity = new MultipartEntity();

//Setup form parameters
multiPartEntity.addPart("source-assembly", new StringBody(src_assembly)); //reference assembly
multiPartEntity.addPart("annot1", new StringBody(annot1)); //query input as a text
multiPartEntity.addPart("api_protocol_version", new StringBody("1.0")); //API version
//query as an input file
FileBody fileBody = new FileBody(annot, "application/text");
multiPartEntity.addPart("annot", fileBody);
httpPost.setEntity(multiPartEntity);
ResponseHandler<String> responseHandler = new BasicResponseHandler();

//httpPost.
// / httpClient

try {
result = httpClient.execute(httpPost, responseHandler);
String jobIdLine = result.substring(0, result.indexOf("\n") + 1); //first line contains job id
result = jobIdLine + result.substring(result.indexOf("##")); //actual query result starts with lines beginning with '##'
}
finally {
httpClient.getConnectionManager().shutdown();
}
return result;
}

}
Loading

0 comments on commit 57394b9

Please sign in to comment.