Skip to content

Commit

Permalink
Original files import
Browse files Browse the repository at this point in the history
Import original files from SVN
  • Loading branch information
Razumain committed May 4, 2016
1 parent 0befd8f commit 3d39c81
Show file tree
Hide file tree
Showing 516 changed files with 170,038 additions and 0 deletions.
111 changes: 111 additions & 0 deletions TslTrustCode/admin-maintenance/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,111 @@
<?xml version="1.0"?>
<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>
<parent>
<artifactId>tsl-trust</artifactId>
<groupId>se.tillvaxtverket.tsltrust</groupId>
<version>1.2</version>
</parent>
<artifactId>admin-maintenance</artifactId>
<name>TT Admin Maintenance</name>
<url>http://maven.apache.org</url>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
<encoding>${project.build.sourceEncoding}</encoding>
</configuration>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<executions>
<execution>
<id>create-executable-jar</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<descriptorRefs>
<descriptorRef>jar-with-dependencies</descriptorRef>
</descriptorRefs>
<archive>
<manifest>
<mainClass>se.tillvaxtverket.tsltrust.admin.maint.TTAdminMaintenance</mainClass>
</manifest>
</archive>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<version>2.4.3</version>
<configuration>
<encoding>${project.build.sourceEncoding}</encoding>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>osxappbundle-maven-plugin</artifactId>
<version>1.0-alpha-1</version>
<configuration>
<mainClass>se.tillvaxtverket.tsltrust.admin.maint.TTAdminMaintenance</mainClass>
<iconFile>${basedir}/src/main/app-resources/sigtest.icns</iconFile>
</configuration>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>bundle</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>


<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<netbeans.hint.license>tillvaxtverket-tsltrust</netbeans.hint.license>
</properties>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.swinglabs</groupId>
<artifactId>swing-layout</artifactId>
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>admin-weblogic</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>at.iaik.jce</groupId>
<artifactId>iaik-jce-full</artifactId>
<version>4.0</version>
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>sigval-validation</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.xerial</groupId>
<artifactId>sqlite-jdbc</artifactId>
</dependency>
</dependencies>
</project>
42 changes: 42 additions & 0 deletions TslTrustCode/admin-maintenance/src/main/app-resources/build.plist
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist SYSTEM "file://localhost/System/Library/DTDs/PropertyList.dtd">
<plist version="0.9">
<dict>
<key>CFBundleName</key>
<string>Signservice Test Tool</string>
<key>CFBundleVersion</key>
<string>1.0</string>
<key>CFBundleAllowMixedLocalizations</key>
<string>true</string>
<key>CFBundleExecutable</key>
<string>JavaApplicationStub</string>
<key>CFBundleDevelopmentRegion</key>
<string>English</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleIconFile</key>
<string>${iconFile}</string>
<key>Java</key>
<dict>
<key>MainClass</key>
<string>${mainClass}</string>
<key>JVMVersion</key>
<string>1.4+</string>
<key>ClassPath</key>
${classpath}
<key>VMOptions</key>
<string>-Xmx256m -Xms128m</string>
<key>Properties</key>
<dict>
<key>apple.laf.useScreenMenuBar</key>
<string>true</string>
<key>apple.awt.showGrowBox</key>
<string>true</string>
</dict>
</dict>
</dict>
</plist>
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
/*
* Copyright 2012 Swedish Agency for Economic and Regional Growth - Tillväxtverket
*
* Licensed under the EUPL, Version 1.1 or ñ as soon they will be approved by the
* European Commission - subsequent versions of the EUPL (the "Licence");
* You may not use this work except in compliance with the Licence.
* You may obtain a copy of the Licence at:
*
* http://joinup.ec.europa.eu/software/page/eupl
*
* Unless required by applicable law or agreed to in writing, software distributed
* under the Licence is distributed on an "AS IS" basis,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the Licence for the specific language governing permissions and limitations
* under the Licence.
*/
package se.tillvaxtverket.tsltrust.admin.maint;

import java.text.SimpleDateFormat;
import se.tillvaxtverket.tsltrust.common.utils.general.ColorPane;
import java.util.Date;
import java.util.LinkedList;
import javax.swing.JTextPane;

/**
* This class provides basic functions for adding text to the console window in the
* admin daemon frame. This class is a subclass of the ColorPane class.
*/
public class Console extends ColorPane {

/**
* Simple Date format "yyyy-MM-dd HH:mm:ss"
*/
static final SimpleDateFormat TIME_FORMAT = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
String blanks = "";

/**
* Console constructor
* @param jTextPane The JTextPane component where the console text is to be displayed
* @param space the number of space characters that will separate display strings
*/
public Console(JTextPane jTextPane, int space) {
super(jTextPane);
for (int i = 0; i < space; i++) {
blanks += " ";
}
}

/**
* Clears the console window
*/
public void clear() {
pane.setText("");
sd = pane.getStyledDocument();
tempBuffer = "";
paneStyles = new LinkedList<StyleAttributes>();
}

/**
* Adding a text string to the console
* @param t1 string to be displayed
* @param styles Color Pane styles
*/
public void add(String t1, String[] styles) {
String time = TIME_FORMAT.format(new Date());
add(new String[]{time, t1}, styles);
}

/**
* Adding two text strings to the console
* @param t1 first string
* @param t2 second string
* @param styles ColorPane styles
*/
public void add(String t1, String t2, String[] styles) {
String time = TIME_FORMAT.format(new Date());
add(new String[]{time, t1, t2}, styles);
}

/**
* Adding an arbitrary array of strings to the console using provided styles
* @param inpStrings Array of strings
* @param styles Array of ColorPane styles
*/
public void add(String[] inpStrings, String[] styles) {
int is = inpStrings.length;
int st = styles.length;
int max = (is < st) ? is : st;
boolean added = false;

for (int i = 0; i < max; i++) {
addStyledText(inpStrings[i] + blanks, styles[i]);
added = true;
}
if (is > max) {
for (int i = max; i < is; i++) {
addPlainText(inpStrings[i] + blanks);
added = true;
}
}
if (added) {
addLF();
}
renderText();
}
}
Loading

0 comments on commit 3d39c81

Please sign in to comment.