congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
Os.rename
Code IndexAdd Tabnine to your IDE (free)

How to use
rename
method
in
libcore.io.Os

Best Java code snippets using libcore.io.Os.rename (Showing top 14 results out of 315)

origin: robovm/robovm

public void rename(String oldPath, String newPath) throws ErrnoException { os.rename(oldPath, newPath); }
public long sendfile(FileDescriptor outFd, FileDescriptor inFd, MutableLong inOffset, long byteCount) throws ErrnoException { return os.sendfile(outFd, inFd, inOffset, byteCount); }
origin: robovm/robovm

/**
 * Renames this file to {@code newPath}. This operation is supported for both
 * files and directories.
 *
 * <p>Many failures are possible. Some of the more likely failures include:
 * <ul>
 * <li>Write permission is required on the directories containing both the source and
 * destination paths.
 * <li>Search permission is required for all parents of both paths.
 * <li>Both paths be on the same mount point. On Android, applications are most likely to hit
 * this restriction when attempting to copy between internal storage and an SD card.
 * </ul>
 *
 * <p>Note that this method does <i>not</i> throw {@code IOException} on failure.
 * Callers must check the return value.
 *
 * @param newPath the new path.
 * @return true on success.
 */
public boolean renameTo(File newPath) {
  try {
    Libcore.os.rename(path, newPath.path);
    return true;
  } catch (ErrnoException errnoException) {
    return false;
  }
}
origin: ibinti/bugvm

public void rename(String oldPath, String newPath) throws ErrnoException { os.rename(oldPath, newPath); }
public long sendfile(FileDescriptor outFd, FileDescriptor inFd, MutableLong inOffset, long byteCount) throws ErrnoException { return os.sendfile(outFd, inFd, inOffset, byteCount); }
origin: com.mobidevelop.robovm/robovm-rt

public void rename(String oldPath, String newPath) throws ErrnoException { os.rename(oldPath, newPath); }
public long sendfile(FileDescriptor outFd, FileDescriptor inFd, MutableLong inOffset, long byteCount) throws ErrnoException { return os.sendfile(outFd, inFd, inOffset, byteCount); }
origin: com.bugvm/bugvm-rt

public void rename(String oldPath, String newPath) throws ErrnoException { os.rename(oldPath, newPath); }
public long sendfile(FileDescriptor outFd, FileDescriptor inFd, MutableLong inOffset, long byteCount) throws ErrnoException { return os.sendfile(outFd, inFd, inOffset, byteCount); }
origin: MobiVM/robovm

public void rename(String oldPath, String newPath) throws ErrnoException { os.rename(oldPath, newPath); }
public long sendfile(FileDescriptor outFd, FileDescriptor inFd, MutableLong inOffset, long byteCount) throws ErrnoException { return os.sendfile(outFd, inFd, inOffset, byteCount); }
origin: FlexoVM/flexovm

public void rename(String oldPath, String newPath) throws ErrnoException { os.rename(oldPath, newPath); }
public long sendfile(FileDescriptor outFd, FileDescriptor inFd, MutableLong inOffset, long byteCount) throws ErrnoException { return os.sendfile(outFd, inFd, inOffset, byteCount); }
origin: com.gluonhq/robovm-rt

public void rename(String oldPath, String newPath) throws ErrnoException { os.rename(oldPath, newPath); }
public long sendfile(FileDescriptor outFd, FileDescriptor inFd, MutableLong inOffset, long byteCount) throws ErrnoException { return os.sendfile(outFd, inFd, inOffset, byteCount); }
origin: MobiVM/robovm

/**
 * Renames this file to {@code newPath}. This operation is supported for both
 * files and directories.
 *
 * <p>Many failures are possible. Some of the more likely failures include:
 * <ul>
 * <li>Write permission is required on the directories containing both the source and
 * destination paths.
 * <li>Search permission is required for all parents of both paths.
 * <li>Both paths be on the same mount point. On Android, applications are most likely to hit
 * this restriction when attempting to copy between internal storage and an SD card.
 * </ul>
 *
 * <p>Note that this method does <i>not</i> throw {@code IOException} on failure.
 * Callers must check the return value.
 *
 * @param newPath the new path.
 * @return true on success.
 */
public boolean renameTo(File newPath) {
  try {
    Libcore.os.rename(path, newPath.path);
    return true;
  } catch (ErrnoException errnoException) {
    return false;
  }
}
origin: com.bugvm/bugvm-rt

/**
 * Renames this file to {@code newPath}. This operation is supported for both
 * files and directories.
 *
 * <p>Many failures are possible. Some of the more likely failures include:
 * <ul>
 * <li>Write permission is required on the directories containing both the source and
 * destination paths.
 * <li>Search permission is required for all parents of both paths.
 * <li>Both paths be on the same mount point. On Android, applications are most likely to hit
 * this restriction when attempting to copy between internal storage and an SD card.
 * </ul>
 *
 * <p>Note that this method does <i>not</i> throw {@code IOException} on failure.
 * Callers must check the return value.
 *
 * @param newPath the new path.
 * @return true on success.
 */
public boolean renameTo(File newPath) {
  try {
    Libcore.os.rename(path, newPath.path);
    return true;
  } catch (ErrnoException errnoException) {
    return false;
  }
}
origin: com.gluonhq/robovm-rt

/**
 * Renames this file to {@code newPath}. This operation is supported for both
 * files and directories.
 *
 * <p>Many failures are possible. Some of the more likely failures include:
 * <ul>
 * <li>Write permission is required on the directories containing both the source and
 * destination paths.
 * <li>Search permission is required for all parents of both paths.
 * <li>Both paths be on the same mount point. On Android, applications are most likely to hit
 * this restriction when attempting to copy between internal storage and an SD card.
 * </ul>
 *
 * <p>Note that this method does <i>not</i> throw {@code IOException} on failure.
 * Callers must check the return value.
 *
 * @param newPath the new path.
 * @return true on success.
 */
public boolean renameTo(File newPath) {
  try {
    Libcore.os.rename(path, newPath.path);
    return true;
  } catch (ErrnoException errnoException) {
    return false;
  }
}
origin: ibinti/bugvm

/**
 * Renames this file to {@code newPath}. This operation is supported for both
 * files and directories.
 *
 * <p>Many failures are possible. Some of the more likely failures include:
 * <ul>
 * <li>Write permission is required on the directories containing both the source and
 * destination paths.
 * <li>Search permission is required for all parents of both paths.
 * <li>Both paths be on the same mount point. On Android, applications are most likely to hit
 * this restriction when attempting to copy between internal storage and an SD card.
 * </ul>
 *
 * <p>Note that this method does <i>not</i> throw {@code IOException} on failure.
 * Callers must check the return value.
 *
 * @param newPath the new path.
 * @return true on success.
 */
public boolean renameTo(File newPath) {
  try {
    Libcore.os.rename(path, newPath.path);
    return true;
  } catch (ErrnoException errnoException) {
    return false;
  }
}
origin: com.mobidevelop.robovm/robovm-rt

/**
 * Renames this file to {@code newPath}. This operation is supported for both
 * files and directories.
 *
 * <p>Many failures are possible. Some of the more likely failures include:
 * <ul>
 * <li>Write permission is required on the directories containing both the source and
 * destination paths.
 * <li>Search permission is required for all parents of both paths.
 * <li>Both paths be on the same mount point. On Android, applications are most likely to hit
 * this restriction when attempting to copy between internal storage and an SD card.
 * </ul>
 *
 * <p>Note that this method does <i>not</i> throw {@code IOException} on failure.
 * Callers must check the return value.
 *
 * @param newPath the new path.
 * @return true on success.
 */
public boolean renameTo(File newPath) {
  try {
    Libcore.os.rename(path, newPath.path);
    return true;
  } catch (ErrnoException errnoException) {
    return false;
  }
}
origin: FlexoVM/flexovm

/**
 * Renames this file to {@code newPath}. This operation is supported for both
 * files and directories.
 *
 * <p>Many failures are possible. Some of the more likely failures include:
 * <ul>
 * <li>Write permission is required on the directories containing both the source and
 * destination paths.
 * <li>Search permission is required for all parents of both paths.
 * <li>Both paths be on the same mount point. On Android, applications are most likely to hit
 * this restriction when attempting to copy between internal storage and an SD card.
 * </ul>
 *
 * <p>Note that this method does <i>not</i> throw {@code IOException} on failure.
 * Callers must check the return value.
 *
 * @param newPath the new path.
 * @return true on success.
 */
public boolean renameTo(File newPath) {
  try {
    Libcore.os.rename(path, newPath.path);
    return true;
  } catch (ErrnoException errnoException) {
    return false;
  }
}
libcore.ioOsrename

Popular methods of Os

  • accept
  • access
  • bind
  • chmod
  • chown
  • close
  • connect
  • dup
  • dup2
  • environ
  • execv
  • execve
  • execv,
  • execve,
  • fchmod,
  • fchown,
  • fcntlFlock,
  • fcntlLong,
  • fcntlVoid,
  • fdatasync,
  • fstat,
  • fstatvfs

Popular in Java

  • Finding current android device location
  • runOnUiThread (Activity)
  • requestLocationUpdates (LocationManager)
  • onCreateOptionsMenu (Activity)
  • Font (java.awt)
    The Font class represents fonts, which are used to render text in a visible way. A font provides the
  • GridBagLayout (java.awt)
    The GridBagLayout class is a flexible layout manager that aligns components vertically and horizonta
  • Menu (java.awt)
  • Calendar (java.util)
    Calendar is an abstract base class for converting between a Date object and a set of integer fields
  • Response (javax.ws.rs.core)
    Defines the contract between a returned instance and the runtime when an application needs to provid
  • Logger (org.apache.log4j)
    This is the central class in the log4j package. Most logging operations, except configuration, are d
  • Github Copilot alternatives
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now