发布/订阅系统路由重配算法,可应用于ad hoc环境
源代码在线查看: request.java
/* * project: RebecaSim * package: broker * file: Request.java * * version: 0.1 * date: 13.05.2005 * * This software is part of the diploma thesis "Ein adaptives Brokernetz * für Publish/Subscribe Systeme". */ package com; import broker.Broker; /** * TODO Insert class description here. * * @version 13.05.2005 * @author parzy */ public class Request extends Message{ private Broker[] path; private double[] costs; public Request(Broker[] path, double[] costs) { this(path, costs, Message.HEURISTIC); } public Request(Broker[] path, double[] costs, int type){ super(type); this.path = path; this.costs = costs; } /** * @return Returns the costs. */ public double[] getCosts() { return costs; } /** * @param costs The costs to set. */ public void setCosts(double[] costs) { this.costs = costs; } /** * @return Returns the path. */ public Broker[] getPath() { return path; } }