001/* 002 GRANITE DATA SERVICES 003 Copyright (C) 2011 GRANITE DATA SERVICES S.A.S. 004 005 This file is part of Granite Data Services. 006 007 Granite Data Services is free software; you can redistribute it and/or modify 008 it under the terms of the GNU Library General Public License as published by 009 the Free Software Foundation; either version 2 of the License, or (at your 010 option) any later version. 011 012 Granite Data Services is distributed in the hope that it will be useful, but 013 WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 014 FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public License 015 for more details. 016 017 You should have received a copy of the GNU Library General Public License 018 along with this library; if not, see <http://www.gnu.org/licenses/>. 019*/ 020 021package flex.messaging.messages; 022 023/** 024 * @author Franck WOLFF 025 */ 026public class RemotingMessage extends AsyncMessage { 027 028 private static final long serialVersionUID = 1L; 029 030 private String source; 031 private String operation; 032 private Object[] parameters; // Since BlazeDS 4 033 private String remoteUsername; // Since BlazeDS 4 034 private String remotePassword; // Since BlazeDS 4 035 036 037 public RemotingMessage() { 038 super(); 039 } 040 041 public String getSource() { 042 return source; 043 } 044 045 public void setSource(String source) { 046 this.source = source; 047 } 048 049 public String getOperation() { 050 return operation; 051 } 052 053 public void setOperation(String operation) { 054 this.operation = operation; 055 } 056 057 public Object[] getParameters() { 058 return parameters; 059 } 060 061 public void setParameters(Object[] parameters) { 062 this.parameters = parameters; 063 } 064 065 public String getRemoteUsername() { 066 return remoteUsername; 067 } 068 069 public void setRemoteUsername(String remoteUsername) { 070 this.remoteUsername = remoteUsername; 071 } 072 073 public String getRemotePassword() { 074 return remotePassword; 075 } 076 077 public void setRemotePassword(String remotePassword) { 078 this.remotePassword = remotePassword; 079 } 080 081 @Override 082 public String toString() { 083 return toString(""); 084 } 085 086 @Override 087 public String toString(String indent) { 088 StringBuilder sb = new StringBuilder(512); 089 sb.append(getClass().getName()).append(" {"); 090 sb.append('\n').append(indent).append(" source = ").append(source); 091 sb.append('\n').append(indent).append(" operation = ").append(operation); 092 sb.append('\n').append(indent).append(" remoteUsername = ").append(remoteUsername); 093 sb.append('\n').append(indent).append(" remotePassword = ").append(remotePassword != null ? "****" : "null"); 094 super.toString(sb, indent, null); 095 sb.append('\n').append(indent).append('}'); 096 return sb.toString(); 097 } 098}