Search in sources :

Example 1 with JavaSVNManager

use of com.kyj.scm.manager.svn.java.JavaSVNManager in project Gargoyle by callakrsos.

the class ScmCommitCompositeExam method start.

/* (non-Javadoc)
	 * @see javafx.application.Application#start(javafx.stage.Stage)
	 */
@Override
public void start(Stage primaryStage) throws Exception {
    Properties properties = new Properties();
    properties.put(JavaSVNManager.SVN_URL, "svn://10.40.41.49");
    //		properties.put(JavaSVNManager.SVN_USER_ID, "kyjun.kim");
    //		properties.put(JavaSVNManager.SVN_USER_PASS, "kyjun.kim");
    FxSVNHistoryDataSupplier svnDataSupplier = new FxSVNHistoryDataSupplier(new JavaSVNManager(properties));
    SvnChagnedCodeComposite svnChagnedCodeComposite = new SvnChagnedCodeComposite(svnDataSupplier);
    ScmCommitComposite scmCommitComposite = new ScmCommitComposite(svnDataSupplier);
    TabPane tabPane = new TabPane();
    tabPane.getTabs().addAll(new Tab("Chagned Codes.", svnChagnedCodeComposite), new Tab("Commit Hist.", scmCommitComposite));
    primaryStage.setScene(new Scene(tabPane));
    primaryStage.show();
}
Also used : JavaSVNManager(com.kyj.scm.manager.svn.java.JavaSVNManager) TabPane(javafx.scene.control.TabPane) Tab(javafx.scene.control.Tab) ScmCommitComposite(com.kyj.fx.voeditor.visual.component.scm.ScmCommitComposite) SvnChagnedCodeComposite(com.kyj.fx.voeditor.visual.component.scm.SvnChagnedCodeComposite) FxSVNHistoryDataSupplier(com.kyj.fx.voeditor.visual.component.scm.FxSVNHistoryDataSupplier) Properties(java.util.Properties) Scene(javafx.scene.Scene)

Example 2 with JavaSVNManager

use of com.kyj.scm.manager.svn.java.JavaSVNManager in project Gargoyle by callakrsos.

the class SVNListTest method recently.

@Test
public void recently() {
    Properties properties = new Properties();
    properties.put(JavaSVNManager.SVN_URL, "http://localhost:11121/svn/sample2/");
    properties.put(JavaSVNManager.SVN_USER_ID, "kyjun.kim");
    properties.put(JavaSVNManager.SVN_USER_PASS, "kyjun.kim");
    JavaSVNManager manager = new JavaSVNManager(properties);
    List<SVNDirEntry> listEntry = manager.listEntry("/", "-1", System.err::println);
    listEntry.forEach(System.out::println);
}
Also used : JavaSVNManager(com.kyj.scm.manager.svn.java.JavaSVNManager) SVNDirEntry(org.tmatesoft.svn.core.SVNDirEntry) Properties(java.util.Properties) Test(org.junit.Test)

Example 3 with JavaSVNManager

use of com.kyj.scm.manager.svn.java.JavaSVNManager in project Gargoyle by callakrsos.

the class CommandTest2 method setting.

@Before
public void setting() throws Exception {
    Properties properties = new Properties();
    properties.put(JavaSVNManager.SVN_URL, "https://dev.naver.com/svn/javafxvoeditor");
    properties.put(JavaSVNManager.SVN_USER_ID, "");
    properties.put(JavaSVNManager.SVN_USER_PASS, "");
    new ProxyInitializable().initialize();
    // properties.put(SVNManager.URL,
    // "https://dev.naver.com/svn/javafxvoeditor");
    manager = new JavaSVNManager(properties);
}
Also used : JavaSVNManager(com.kyj.scm.manager.svn.java.JavaSVNManager) ProxyInitializable(com.kyj.fx.voeditor.visual.main.initalize.ProxyInitializable) Properties(java.util.Properties) Before(org.junit.Before)

Example 4 with JavaSVNManager

use of com.kyj.scm.manager.svn.java.JavaSVNManager in project Gargoyle by callakrsos.

the class SVNTreeView method menuPropertiesOnAction.

/**
	 * @작성자 : KYJ
	 * @작성일 : 2016. 8. 8.
	 * @param e
	 * @throws IOException
	 */
public void menuPropertiesOnAction(ActionEvent e) {
    TreeItem<SVNItem> selectedItem = getSelectionModel().getSelectedItem();
    try {
        if (selectedItem != null) {
            SVNItem value = selectedItem.getValue();
            Properties properties = value.getManager().getProperties();
            FXMLLoader fxmlLoader = new FXMLLoader(SVNTreeView.class.getResource("AddNewSVNRepositoryView.fxml"));
            BorderPane n = fxmlLoader.load();
            Stage window = (Stage) getParent().getScene().getWindow();
            Stage parent = (Stage) com.kyj.fx.voeditor.visual.util.ValueUtil.decode(window, window, SharedMemory.getPrimaryStage());
            Stage stage = new Stage();
            AddNewSVNRepositoryController controller = fxmlLoader.getController();
            controller.setStage(stage);
            controller.setProperties(properties);
            stage.setScene(new Scene(n));
            stage.setResizable(false);
            stage.initOwner(parent);
            stage.setTitle("Modify Location.");
            stage.centerOnScreen();
            stage.showAndWait();
            Properties result = controller.getResult();
            if (result != null) {
                SVNItem newSVNItem = new SVNRepository(new JavaSVNManager(result));
                TreeItem<SVNItem> createNode = scmTreeMaker.createNode(newSVNItem, null);
                getRoot().getChildren().remove(selectedItem);
                getRoot().getChildren().add(createNode);
            }
        }
    } catch (Exception ex) {
        LOGGER.error(ValueUtil.toString(ex));
    }
}
Also used : JavaSVNManager(com.kyj.scm.manager.svn.java.JavaSVNManager) BorderPane(javafx.scene.layout.BorderPane) Stage(javafx.stage.Stage) Properties(java.util.Properties) Scene(javafx.scene.Scene) FXMLLoader(javafx.fxml.FXMLLoader) SVNException(org.tmatesoft.svn.core.SVNException) IOException(java.io.IOException)

Example 5 with JavaSVNManager

use of com.kyj.scm.manager.svn.java.JavaSVNManager in project Gargoyle by callakrsos.

the class SVNTreeView method menuAddNewLocationOnAction.

/**
	 * 새로운 레포지토리를 추가한다.
	 *
	 * @작성자 : KYJ
	 * @작성일 : 2016. 4. 3.
	 * @param e
	 */
public void menuAddNewLocationOnAction(ActionEvent e) {
    try {
        FXMLLoader fxmlLoader = new FXMLLoader(SVNTreeView.class.getResource("AddNewSVNRepositoryView.fxml"));
        BorderPane n = fxmlLoader.load();
        Stage window = (Stage) getParent().getScene().getWindow();
        Stage parent = (Stage) com.kyj.fx.voeditor.visual.util.ValueUtil.decode(window, window, SharedMemory.getPrimaryStage());
        Stage stage = new Stage();
        AddNewSVNRepositoryController controller = fxmlLoader.getController();
        controller.setStage(stage);
        stage.setScene(new Scene(n));
        stage.setResizable(false);
        stage.initOwner(parent);
        stage.setTitle("Add New Location.");
        stage.centerOnScreen();
        stage.showAndWait();
        Properties result = controller.getResult();
        if (result != null) {
            SVNItem newSVNItem = new SVNRepository(new JavaSVNManager(result));
            TreeItem<SVNItem> createNode = scmTreeMaker.createNode(newSVNItem, null);
            getRoot().getChildren().add(createNode);
        }
    } catch (IOException e1) {
        LOGGER.error(ValueUtil.toString(e1));
    }
}
Also used : JavaSVNManager(com.kyj.scm.manager.svn.java.JavaSVNManager) BorderPane(javafx.scene.layout.BorderPane) Stage(javafx.stage.Stage) IOException(java.io.IOException) Scene(javafx.scene.Scene) Properties(java.util.Properties) FXMLLoader(javafx.fxml.FXMLLoader)

Aggregations

JavaSVNManager (com.kyj.scm.manager.svn.java.JavaSVNManager)6 Properties (java.util.Properties)6 Scene (javafx.scene.Scene)3 IOException (java.io.IOException)2 FXMLLoader (javafx.fxml.FXMLLoader)2 BorderPane (javafx.scene.layout.BorderPane)2 Stage (javafx.stage.Stage)2 FxSVNHistoryDataSupplier (com.kyj.fx.voeditor.visual.component.scm.FxSVNHistoryDataSupplier)1 SVNRepository (com.kyj.fx.voeditor.visual.component.scm.SVNRepository)1 ScmCommitComposite (com.kyj.fx.voeditor.visual.component.scm.ScmCommitComposite)1 SvnChagnedCodeComposite (com.kyj.fx.voeditor.visual.component.scm.SvnChagnedCodeComposite)1 ProxyInitializable (com.kyj.fx.voeditor.visual.main.initalize.ProxyInitializable)1 ArrayList (java.util.ArrayList)1 List (java.util.List)1 Tab (javafx.scene.control.Tab)1 TabPane (javafx.scene.control.TabPane)1 JSONArray (org.json.simple.JSONArray)1 JSONObject (org.json.simple.JSONObject)1 JSONParser (org.json.simple.parser.JSONParser)1 ParseException (org.json.simple.parser.ParseException)1