FreeRDP
Loading...
Searching...
No Matches
com.freerdp.freerdpcore.domain.BookmarkBase Class Reference
Inheritance diagram for com.freerdp.freerdpcore.domain.BookmarkBase:
Collaboration diagram for com.freerdp.freerdpcore.domain.BookmarkBase:

Data Structures

class  AdvancedSettings
 
class  DebugSettings
 
class  GatewaySettings
 
class  PerformanceFlags
 
class  ScreenSettings
 

Public Member Functions

 BookmarkBase (Parcel parcel)
 
int getType ()
 
void setType (int type)
 
long getId ()
 
void setId (long id)
 
String getLabel ()
 
void setLabel (String label)
 
String getUsername ()
 
void setUsername (String username)
 
String getPassword ()
 
void setPassword (String password)
 
String getDomain ()
 
void setDomain (String domain)
 
ScreenSettings getScreenSettings ()
 
void setScreenSettings (ScreenSettings screenSettings)
 
PerformanceFlags getPerformanceFlags ()
 
void setPerformanceFlags (PerformanceFlags performanceFlags)
 
AdvancedSettings getAdvancedSettings ()
 
void setAdvancedSettings (AdvancedSettings advancedSettings)
 
DebugSettings getDebugSettings ()
 
void setDebugSettings (DebugSettings debugSettings)
 
String getHostname ()
 
void setHostname (String hostname)
 
int getPort ()
 
void setPort (int port)
 
boolean getEnableGatewaySettings ()
 
void setEnableGatewaySettings (boolean enableGatewaySettings)
 
GatewaySettings getGatewaySettings ()
 
void setGatewaySettings (GatewaySettings gatewaySettings)
 
boolean isDirectConnect ()
 
void setDirectConnect (boolean directConnect)
 
ScreenSettings getActiveScreenSettings ()
 
PerformanceFlags getActivePerformanceFlags ()
 
int describeContents ()
 
void writeToParcel (Parcel out, int flags)
 
void writeToSharedPreferences (SharedPreferences sharedPrefs)
 
void readFromSharedPreferences (SharedPreferences sharedPrefs)
 
Object clone ()
 

Static Public Attributes

static final int TYPE_INVALID = -1
 
static final int TYPE_MANUAL = 1
 
static final int TYPE_QUICKCONNECT = 2
 
static final int TYPE_CUSTOM_BASE = 1000
 
static final Parcelable.Creator< BookmarkBaseCREATOR
 

Protected Attributes

int type
 

Detailed Description

Definition at line 21 of file BookmarkBase.java.

Constructor & Destructor Documentation

◆ BookmarkBase() [1/2]

com.freerdp.freerdpcore.domain.BookmarkBase.BookmarkBase ( Parcel  parcel)
inline

Definition at line 55 of file BookmarkBase.java.

56 {
57 type = parcel.readInt();
58 id = parcel.readLong();
59 label = parcel.readString();
60 username = parcel.readString();
61 password = parcel.readString();
62 domain = parcel.readString();
63
64 screenSettings = parcel.readParcelable(ScreenSettings.class.getClassLoader());
65 performanceFlags = parcel.readParcelable(PerformanceFlags.class.getClassLoader());
66 advancedSettings = parcel.readParcelable(AdvancedSettings.class.getClassLoader());
67 debugSettings = parcel.readParcelable(DebugSettings.class.getClassLoader());
68 hostname = parcel.readString();
69 port = parcel.readInt();
70 enableGatewaySettings = (parcel.readInt() == 1);
71 gatewaySettings = parcel.readParcelable(GatewaySettings.class.getClassLoader());
72 directConnect = (parcel.readInt() == 1);
73 }

◆ BookmarkBase() [2/2]

com.freerdp.freerdpcore.domain.BookmarkBase.BookmarkBase ( )
inline

Definition at line 75 of file BookmarkBase.java.

76 {
77 init();
78 }

Member Function Documentation

◆ clone()

Object com.freerdp.freerdpcore.domain.BookmarkBase.clone ( )
inline

Definition at line 398 of file BookmarkBase.java.

399 {
400 try
401 {
402 return super.clone();
403 }
404 catch (CloneNotSupportedException e)
405 {
406 return null;
407 }
408 }

◆ describeContents()

int com.freerdp.freerdpcore.domain.BookmarkBase.describeContents ( )
inline

Definition at line 261 of file BookmarkBase.java.

262 {
263 return 0;
264 }

◆ getActivePerformanceFlags()

PerformanceFlags com.freerdp.freerdpcore.domain.BookmarkBase.getActivePerformanceFlags ( )
inline

Definition at line 256 of file BookmarkBase.java.

257 {
258 return performanceFlags;
259 }

◆ getActiveScreenSettings()

ScreenSettings com.freerdp.freerdpcore.domain.BookmarkBase.getActiveScreenSettings ( )
inline

Definition at line 251 of file BookmarkBase.java.

252 {
253 return screenSettings;
254 }

◆ getAdvancedSettings()

AdvancedSettings com.freerdp.freerdpcore.domain.BookmarkBase.getAdvancedSettings ( )
inline

Definition at line 181 of file BookmarkBase.java.

182 {
183 return advancedSettings;
184 }

◆ getDebugSettings()

DebugSettings com.freerdp.freerdpcore.domain.BookmarkBase.getDebugSettings ( )
inline

Definition at line 191 of file BookmarkBase.java.

192 {
193 return debugSettings;
194 }

◆ getDomain()

String com.freerdp.freerdpcore.domain.BookmarkBase.getDomain ( )
inline

Definition at line 151 of file BookmarkBase.java.

152 {
153 return domain;
154 }

◆ getEnableGatewaySettings()

boolean com.freerdp.freerdpcore.domain.BookmarkBase.getEnableGatewaySettings ( )
inline

Definition at line 221 of file BookmarkBase.java.

222 {
223 return enableGatewaySettings;
224 }

◆ getGatewaySettings()

GatewaySettings com.freerdp.freerdpcore.domain.BookmarkBase.getGatewaySettings ( )
inline

Definition at line 231 of file BookmarkBase.java.

232 {
233 return gatewaySettings;
234 }

◆ getHostname()

String com.freerdp.freerdpcore.domain.BookmarkBase.getHostname ( )
inline

Definition at line 201 of file BookmarkBase.java.

202 {
203 return hostname;
204 }

◆ getId()

long com.freerdp.freerdpcore.domain.BookmarkBase.getId ( )
inline

Definition at line 111 of file BookmarkBase.java.

112 {
113 return id;
114 }

◆ getLabel()

String com.freerdp.freerdpcore.domain.BookmarkBase.getLabel ( )
inline

Definition at line 121 of file BookmarkBase.java.

122 {
123 return label;
124 }

◆ getPassword()

String com.freerdp.freerdpcore.domain.BookmarkBase.getPassword ( )
inline

Definition at line 141 of file BookmarkBase.java.

142 {
143 return password;
144 }

◆ getPerformanceFlags()

PerformanceFlags com.freerdp.freerdpcore.domain.BookmarkBase.getPerformanceFlags ( )
inline

Definition at line 171 of file BookmarkBase.java.

172 {
173 return performanceFlags;
174 }

◆ getPort()

int com.freerdp.freerdpcore.domain.BookmarkBase.getPort ( )
inline

Definition at line 211 of file BookmarkBase.java.

212 {
213 return port;
214 }

◆ getScreenSettings()

ScreenSettings com.freerdp.freerdpcore.domain.BookmarkBase.getScreenSettings ( )
inline

Definition at line 161 of file BookmarkBase.java.

162 {
163 return screenSettings;
164 }

◆ getType()

int com.freerdp.freerdpcore.domain.BookmarkBase.getType ( )
inline

Definition at line 101 of file BookmarkBase.java.

102 {
103 return type;
104 }

◆ getUsername()

String com.freerdp.freerdpcore.domain.BookmarkBase.getUsername ( )
inline

Definition at line 131 of file BookmarkBase.java.

132 {
133 return username;
134 }

◆ isDirectConnect()

boolean com.freerdp.freerdpcore.domain.BookmarkBase.isDirectConnect ( )
inline

Definition at line 241 of file BookmarkBase.java.

242 {
243 return directConnect;
244 }

◆ readFromSharedPreferences()

void com.freerdp.freerdpcore.domain.BookmarkBase.readFromSharedPreferences ( SharedPreferences  sharedPrefs)
inline

Definition at line 344 of file BookmarkBase.java.

345 {
346 label = sharedPrefs.getString("bookmark.label", "");
347 username = sharedPrefs.getString("bookmark.username", "");
348 password = sharedPrefs.getString("bookmark.password", "");
349 domain = sharedPrefs.getString("bookmark.domain", "");
350
351 screenSettings.setColors(sharedPrefs.getInt("bookmark.colors", 16));
352 screenSettings.setResolution(sharedPrefs.getString("bookmark.resolution", "automatic"),
353 sharedPrefs.getInt("bookmark.width", 800),
354 sharedPrefs.getInt("bookmark.height", 600));
355
356 performanceFlags.setRemoteFX(sharedPrefs.getBoolean("bookmark.perf_remotefx", false));
357 performanceFlags.setGfx(sharedPrefs.getBoolean("bookmark.perf_gfx", true));
358 performanceFlags.setH264(sharedPrefs.getBoolean("bookmark.perf_gfx_h264", true));
359 performanceFlags.setWallpaper(sharedPrefs.getBoolean("bookmark.perf_wallpaper", false));
360 performanceFlags.setFontSmoothing(
361 sharedPrefs.getBoolean("bookmark.perf_font_smoothing", false));
362 performanceFlags.setDesktopComposition(
363 sharedPrefs.getBoolean("bookmark.perf_desktop_composition", false));
364 performanceFlags.setFullWindowDrag(
365 sharedPrefs.getBoolean("bookmark.perf_window_dragging", false));
366 performanceFlags.setMenuAnimations(
367 sharedPrefs.getBoolean("bookmark.perf_menu_animation", false));
368 performanceFlags.setTheming(sharedPrefs.getBoolean("bookmark.perf_themes", false));
369
370 advancedSettings.setTlsSecLevel(sharedPrefs.getInt("bookmark.tlsSecLevel", -1));
371 advancedSettings.setTlsMinLevel(sharedPrefs.getInt("bookmark.tlsMinLevel", -1));
372
373 advancedSettings.setRedirectSDCard(
374 sharedPrefs.getBoolean("bookmark.redirect_sdcard", false));
375 advancedSettings.setRedirectSound(sharedPrefs.getInt("bookmark.redirect_sound", 0));
376 advancedSettings.setRedirectMicrophone(
377 sharedPrefs.getBoolean("bookmark.redirect_microphone", false));
378 advancedSettings.setSecurity(sharedPrefs.getInt("bookmark.security", 0));
379 advancedSettings.setRemoteProgram(sharedPrefs.getString("bookmark.remote_program", ""));
380 advancedSettings.setWorkDir(sharedPrefs.getString("bookmark.work_dir", ""));
381 advancedSettings.setConsoleMode(sharedPrefs.getBoolean("bookmark.console_mode", false));
382
383 debugSettings.setAsyncChannel(sharedPrefs.getBoolean("bookmark.async_channel", true));
384 debugSettings.setAsyncUpdate(sharedPrefs.getBoolean("bookmark.async_update", true));
385 debugSettings.setDebugLevel(sharedPrefs.getString("bookmark.debug_level", "INFO"));
386
387 hostname = sharedPrefs.getString("bookmark.hostname", "");
388 port = sharedPrefs.getInt("bookmark.port", 3389);
389 enableGatewaySettings = sharedPrefs.getBoolean("bookmark.enable_gateway_settings", false);
390 gatewaySettings.setHostname(sharedPrefs.getString("bookmark.gateway_hostname", ""));
391 gatewaySettings.setPort(sharedPrefs.getInt("bookmark.gateway_port", 443));
392 gatewaySettings.setUsername(sharedPrefs.getString("bookmark.gateway_username", ""));
393 gatewaySettings.setPassword(sharedPrefs.getString("bookmark.gateway_password", ""));
394 gatewaySettings.setDomain(sharedPrefs.getString("bookmark.gateway_domain", ""));
395 }

◆ setAdvancedSettings()

void com.freerdp.freerdpcore.domain.BookmarkBase.setAdvancedSettings ( AdvancedSettings  advancedSettings)
inline

Definition at line 186 of file BookmarkBase.java.

187 {
188 this.advancedSettings = advancedSettings;
189 }

◆ setDebugSettings()

void com.freerdp.freerdpcore.domain.BookmarkBase.setDebugSettings ( DebugSettings  debugSettings)
inline

Definition at line 196 of file BookmarkBase.java.

197 {
198 this.debugSettings = debugSettings;
199 }

◆ setDirectConnect()

void com.freerdp.freerdpcore.domain.BookmarkBase.setDirectConnect ( boolean  directConnect)
inline

Definition at line 246 of file BookmarkBase.java.

247 {
248 this.directConnect = directConnect;
249 }

◆ setDomain()

void com.freerdp.freerdpcore.domain.BookmarkBase.setDomain ( String  domain)
inline

Definition at line 156 of file BookmarkBase.java.

157 {
158 this.domain = domain;
159 }

◆ setEnableGatewaySettings()

void com.freerdp.freerdpcore.domain.BookmarkBase.setEnableGatewaySettings ( boolean  enableGatewaySettings)
inline

Definition at line 226 of file BookmarkBase.java.

227 {
228 this.enableGatewaySettings = enableGatewaySettings;
229 }

◆ setGatewaySettings()

void com.freerdp.freerdpcore.domain.BookmarkBase.setGatewaySettings ( GatewaySettings  gatewaySettings)
inline

Definition at line 236 of file BookmarkBase.java.

237 {
238 this.gatewaySettings = gatewaySettings;
239 }

◆ setHostname()

void com.freerdp.freerdpcore.domain.BookmarkBase.setHostname ( String  hostname)
inline

Definition at line 206 of file BookmarkBase.java.

207 {
208 this.hostname = hostname;
209 }

◆ setId()

void com.freerdp.freerdpcore.domain.BookmarkBase.setId ( long  id)
inline

Definition at line 116 of file BookmarkBase.java.

117 {
118 this.id = id;
119 }

◆ setLabel()

void com.freerdp.freerdpcore.domain.BookmarkBase.setLabel ( String  label)
inline

Definition at line 126 of file BookmarkBase.java.

127 {
128 this.label = label;
129 }

◆ setPassword()

void com.freerdp.freerdpcore.domain.BookmarkBase.setPassword ( String  password)
inline

Definition at line 146 of file BookmarkBase.java.

147 {
148 this.password = password;
149 }

◆ setPerformanceFlags()

void com.freerdp.freerdpcore.domain.BookmarkBase.setPerformanceFlags ( PerformanceFlags  performanceFlags)
inline

Definition at line 176 of file BookmarkBase.java.

177 {
178 this.performanceFlags = performanceFlags;
179 }

◆ setPort()

void com.freerdp.freerdpcore.domain.BookmarkBase.setPort ( int  port)
inline

Definition at line 216 of file BookmarkBase.java.

217 {
218 this.port = port;
219 }

◆ setScreenSettings()

void com.freerdp.freerdpcore.domain.BookmarkBase.setScreenSettings ( ScreenSettings  screenSettings)
inline

Definition at line 166 of file BookmarkBase.java.

167 {
168 this.screenSettings = screenSettings;
169 }

◆ setType()

void com.freerdp.freerdpcore.domain.BookmarkBase.setType ( int  type)
inline

Definition at line 106 of file BookmarkBase.java.

107 {
108 this.type = type;
109 }

◆ setUsername()

void com.freerdp.freerdpcore.domain.BookmarkBase.setUsername ( String  username)
inline

Definition at line 136 of file BookmarkBase.java.

137 {
138 this.username = username;
139 }

◆ writeToParcel()

void com.freerdp.freerdpcore.domain.BookmarkBase.writeToParcel ( Parcel  out,
int  flags 
)
inline

Definition at line 266 of file BookmarkBase.java.

267 {
268 out.writeInt(type);
269 out.writeLong(id);
270 out.writeString(label);
271 out.writeString(username);
272 out.writeString(password);
273 out.writeString(domain);
274
275 out.writeParcelable(screenSettings, flags);
276 out.writeParcelable(performanceFlags, flags);
277 out.writeParcelable(advancedSettings, flags);
278 out.writeParcelable(debugSettings, flags);
279 out.writeString(hostname);
280 out.writeInt(port);
281 out.writeInt(enableGatewaySettings ? 1 : 0);
282 out.writeParcelable(gatewaySettings, flags);
283 out.writeInt(directConnect ? 1 : 0);
284 }

◆ writeToSharedPreferences()

void com.freerdp.freerdpcore.domain.BookmarkBase.writeToSharedPreferences ( SharedPreferences  sharedPrefs)
inline

Definition at line 287 of file BookmarkBase.java.

288 {
289
290 Locale locale = Locale.ENGLISH;
291
292 SharedPreferences.Editor editor = sharedPrefs.edit();
293 editor.clear();
294 editor.putString("bookmark.label", label);
295 editor.putString("bookmark.username", username);
296 editor.putString("bookmark.password", password);
297 editor.putString("bookmark.domain", domain);
298
299 editor.putInt("bookmark.colors", screenSettings.getColors());
300 editor.putString("bookmark.resolution",
301 screenSettings.getResolutionString().toLowerCase(locale));
302 editor.putInt("bookmark.width", screenSettings.getWidth());
303 editor.putInt("bookmark.height", screenSettings.getHeight());
304
305 editor.putBoolean("bookmark.perf_remotefx", performanceFlags.getRemoteFX());
306 editor.putBoolean("bookmark.perf_gfx", performanceFlags.getGfx());
307 editor.putBoolean("bookmark.perf_gfx_h264", performanceFlags.getH264());
308 editor.putBoolean("bookmark.perf_wallpaper", performanceFlags.getWallpaper());
309 editor.putBoolean("bookmark.perf_font_smoothing", performanceFlags.getFontSmoothing());
310 editor.putBoolean("bookmark.perf_desktop_composition",
311 performanceFlags.getDesktopComposition());
312 editor.putBoolean("bookmark.perf_window_dragging", performanceFlags.getFullWindowDrag());
313 editor.putBoolean("bookmark.perf_menu_animation", performanceFlags.getMenuAnimations());
314 editor.putBoolean("bookmark.perf_themes", performanceFlags.getTheming());
315
316 editor.putInt("bookmark.tlsSecLevel", advancedSettings.tlsSecLevel);
317 editor.putInt("bookmark.tlsMinLevel", advancedSettings.tlsMinLevel);
318
319 editor.putBoolean("bookmark.redirect_sdcard", advancedSettings.getRedirectSDCard());
320 editor.putInt("bookmark.redirect_sound", advancedSettings.getRedirectSound());
321 editor.putBoolean("bookmark.redirect_microphone", advancedSettings.getRedirectMicrophone());
322 editor.putInt("bookmark.security", advancedSettings.getSecurity());
323 editor.putString("bookmark.remote_program", advancedSettings.getRemoteProgram());
324 editor.putString("bookmark.work_dir", advancedSettings.getWorkDir());
325 editor.putBoolean("bookmark.console_mode", advancedSettings.getConsoleMode());
326
327 editor.putBoolean("bookmark.async_channel", debugSettings.getAsyncChannel());
328 editor.putBoolean("bookmark.async_update", debugSettings.getAsyncUpdate());
329 editor.putString("bookmark.debug_level", debugSettings.getDebugLevel());
330
331 editor.putString("bookmark.hostname", hostname);
332 editor.putInt("bookmark.port", port);
333 editor.putBoolean("bookmark.enable_gateway_settings", enableGatewaySettings);
334 editor.putString("bookmark.gateway_hostname", gatewaySettings.getHostname());
335 editor.putInt("bookmark.gateway_port", gatewaySettings.getPort());
336 editor.putString("bookmark.gateway_username", gatewaySettings.getUsername());
337 editor.putString("bookmark.gateway_password", gatewaySettings.getPassword());
338 editor.putString("bookmark.gateway_domain", gatewaySettings.getDomain());
339
340 editor.apply();
341 }

Field Documentation

◆ CREATOR

final Parcelable.Creator<BookmarkBase> com.freerdp.freerdpcore.domain.BookmarkBase.CREATOR
static
Initial value:
=
new Parcelable.Creator<BookmarkBase>() {
public BookmarkBase createFromParcel(Parcel in)
{
return new BookmarkBase(in);
}
@Override public BookmarkBase[] newArray(int size)
{
return new BookmarkBase[size];
}
}

Definition at line 27 of file BookmarkBase.java.

28 {
29 public BookmarkBase createFromParcel(Parcel in)
30 {
31 return new BookmarkBase(in);
32 }
33
34 @Override public BookmarkBase[] newArray(int size)
35 {
36 return new BookmarkBase[size];
37 }
38 };

◆ type

int com.freerdp.freerdpcore.domain.BookmarkBase.type
protected

Definition at line 39 of file BookmarkBase.java.

◆ TYPE_CUSTOM_BASE

final int com.freerdp.freerdpcore.domain.BookmarkBase.TYPE_CUSTOM_BASE = 1000
static

Definition at line 26 of file BookmarkBase.java.

◆ TYPE_INVALID

final int com.freerdp.freerdpcore.domain.BookmarkBase.TYPE_INVALID = -1
static

Definition at line 23 of file BookmarkBase.java.

◆ TYPE_MANUAL

final int com.freerdp.freerdpcore.domain.BookmarkBase.TYPE_MANUAL = 1
static

Definition at line 24 of file BookmarkBase.java.

◆ TYPE_QUICKCONNECT

final int com.freerdp.freerdpcore.domain.BookmarkBase.TYPE_QUICKCONNECT = 2
static

Definition at line 25 of file BookmarkBase.java.


The documentation for this class was generated from the following file: