// Decompiled by Jad v1.5.8e. Copyright 2001 Pavel Kouznetsov. // Jad home page: http://www.geocities.com/kpdus/jad.html // Decompiler options: braces fieldsfirst space lnc package com.olio.communication.notifications.new_notifications.RemoteActions; import android.content.Context; import android.os.Parcel; import android.os.PowerManager; import com.olio.communication.filetransfer.Utilities; import com.olio.communication.messages.MessagePayload; import com.olio.util.ALog; import org.apache.commons.lang3.builder.EqualsBuilder; import org.apache.commons.lang3.builder.HashCodeBuilder; // Referenced classes of package com.olio.communication.notifications.new_notifications.RemoteActions: // RemoteAction public class DeleteFileRemoteAction extends RemoteAction { public static final android.os.Parcelable.Creator CREATOR = new android.os.Parcelable.Creator() { public MessagePayload createFromParcel(Parcel parcel) { return RemoteAction.unpackParcel(parcel); } public volatile Object createFromParcel(Parcel parcel) { return createFromParcel(parcel); } public MessagePayload[] newArray(int i) { return new DeleteFileRemoteAction[i]; } public volatile Object[] newArray(int i) { return newArray(i); } }; private static final long serialVersionUID = 139L; private String filePath; private boolean rebootAfterDelete; public DeleteFileRemoteAction() { } public DeleteFileRemoteAction(String s, boolean flag) { filePath = s; rebootAfterDelete = flag; } public boolean equals(Object obj) { if (this == obj) { return true; } if (obj == null || getClass() != obj.getClass()) { return false; } else { DeleteFileRemoteAction deletefileremoteaction = (DeleteFileRemoteAction)obj; return (new EqualsBuilder()).appendSuper(super.equals(obj)).append(rebootAfterDelete, deletefileremoteaction.rebootAfterDelete).append(filePath, deletefileremoteaction.filePath).isEquals(); } } public String getFilePath() { return filePath; } public int hashCode() { return (new HashCodeBuilder(17, 37)).appendSuper(super.hashCode()).append(filePath).append(rebootAfterDelete).toHashCode(); } public boolean isRebootAfterDelete() { return rebootAfterDelete; } public boolean runAction(Context context, Long long1) { boolean flag = Utilities.deleteFile(filePath); ALog.d("FILE DELETE RESULT %s", new Object[] { Boolean.valueOf(flag) }); logResult(context, long1, flag, String.format("filePath:%s", new Object[] { filePath })); if (rebootAfterDelete) { ALog.d("Rebooting device after delete file", new Object[0]); ((PowerManager)context.getSystemService("power")).reboot(" -p "); } return flag; } public void setFilePath(String s) { filePath = s; } public void setRebootAfterDelete(boolean flag) { rebootAfterDelete = flag; } }