小编Нед*_*ние的帖子

取消对另一个分支的支持


我正在尝试使用TFS Power Tools将我的更改解压缩到另一个分支.我正在尝试执行命令

tfpt unshelve /migrate "NuGet Build" "/source:$/ProjectName/Main/Source" "/target:$/ProjectName/Main/Source-NuGet"
Run Code Online (Sandbox Code Playgroud)

但它会返回消息'tfpt : Unable to determine the workspace'.

我正在从映射到此项目的目录中运行命令.而且我试过用tf workspaces /s:http://our-tfs.

有谁知道如何解决这个问题?

tfs tfs-power-tools branching-and-merging

36
推荐指数
3
解决办法
3万
查看次数

具有RMI调用的ClassLoader

我试图制作简单的java分析器并使用ClassLoader.

这是我对ClassLoader的实现:

import java.rmi.RemoteException;
import java.rmi.registry.LocateRegistry;
import java.rmi.registry.Registry;

public class CustomClassLoader extends ClassLoader {
    private Notifier notifier;

    public CustomClassLoader() {
        super();
    }

    public CustomClassLoader(ClassLoader parent) {
        super(parent);
    }

    private void initNotifier() {
        if (notifier != null) return;
        try {
            System.out.println("2");
            Registry registry = LocateRegistry.getRegistry(Const.registryPort);
            System.out.println("3");
            notifier = (Notifier) registry.lookup(Const.stubName);
            System.out.println("4");
        } catch (Exception e) {
            e.printStackTrace();
            System.exit(1);
        }
    }

    @Override
    protected synchronized Class<?> loadClass(String name, boolean resolve) 
                                    throws ClassNotFoundException {
        System.out.println("0");
        Class clazz = super.loadClass(name, resolve);
        System.out.println("1");
        initNotifier();
        System.out.println("5");
        try …
Run Code Online (Sandbox Code Playgroud)

java profiler rmi classloader

11
推荐指数
1
解决办法
751
查看次数

无法在TypeScript中从文件加载类

我有一个看起来像这样的课:

export module GameModule {
    export class Game {
        private boardContainer: HTMLElement;
        private board: number[][];

        constructor (container: HTMLDivElement) {
            this.boardContainer = container;
            this.board = [[0, 0, 0], [0, 0, 0], [0, 0, 0]];

            this.drawGrid();
        }

        drawGrid() {

        }
    }
}
Run Code Online (Sandbox Code Playgroud)

和主要应用:

import GameModule = module("./GameModule");

window.onload = () => {
    new GameModule.GameModule.Game(<HTMLDivElement> document.getElementById('content'));
};
Run Code Online (Sandbox Code Playgroud)

但是当我尝试编译代码时,我遇到了错误:

>tsc --module amd app.tss
app.tss(1, 27): The name '"./GameModule"' does not exist in the current scope
app.tss(1, 27): A module cannot be aliased to a …
Run Code Online (Sandbox Code Playgroud)

typescript

5
推荐指数
1
解决办法
3205
查看次数