File class in java in hindi
File class in java
Hello guys, in this video you will learn about File class, its constructors, and methods.
Signature:
public class File
extends Object
implements Serializable, Comparable
The File class is defined in the java.io package.
The file class provides an abstract representation of file and directory pathnames. This class presents an abstract, system-independent view of hierarchical pathnames. An abstract pathname has two components:
1. An optional system-dependent prefix string, such as a disk-drive specifier, "/" for the UNIX root directory, or "\\\\" for a Microsoft Windows UNC pathname.
2. A sequence of zero or more string names.
The first name in an abstract pathname may be a directory name or, drive, a hostname.
Each subsequent name in an abstract pathname denotes a directory; the last name may denote either a directory or a file.
Instances of this class may or may not denote an actual file-system object such as a file or a directory.
This class contains methods for working with the pathname, deleting and renaming files, creating new directories, listing the contents of a directory, and determining several common attributes of files and directories.
The File class does not provide any method for reading or writing the contents of the file. File reading and writing operations are performed with the help of the Stream classes, which we will discuss later.
File class constructor
1. File(File parent, String child): Creates a new File instance from a parent abstract pathname and a child pathname string.
2. File(String pathname): Creates a new File instance by converting the given pathname string into an abstract pathname.
3. File(String parent, String child): Creates a new File instance from a parent pathname string and a child pathname string.
4. File(URI uri): Creates a new File instance by converting the given file: URI into an abstract pathname.
The URI class is defined in the java.net package.
In this video we will discuss the following four methods of File class, the rest of the methods will be discussed in the upcoming videos.
Method Signature Method Working
boolean exists() Tests whether the file or directory denoted by this abstract pathname exists.
boolean isDirectory()
Tests whether the file denoted by this abstract pathname is a directory.
boolean isFile()
Tests whether the file denoted by this abstract pathname is a normal file.
String getName() Returns the name of the file or directory denoted by this abstract pathname.
Learn C Language from beginning
https://www.youtube.com/playlist?list=PLZwkYDh1QECvRe8-gEy4Ph7wf8MytR-St
Learn C++ from beginning
https://www.youtube.com/playlist?list=PLZwkYDh1QECuzxXWkTWCVAwlufNDBufH9
Learn Java from beginning
https://www.youtube.com/playlist?list=PLZwkYDh1QECutGr1EhT0D8BwBzo89XRrE
Learn Python from beginning
https://www.youtube.com/playlist?list=PLZwkYDh1QECuTE191SM85sW_0NlBmw01m
Learn PHP from beginning
https://www.youtube.com/playlist?list=PLZwkYDh1QECsxwXPwMSb3zUoaGV8mMtri
www.tarunsir.com
www.cinstitute.org.in
Connect me on LinkedIn https://www.linkedin.com/in/tarrunverrma
https://www.instagram.com/the_ultimate_coding_stuff/
#tarunsir #javatutorial #learnprogramming #java #fileclass #file
Что делает видео по-настоящему запоминающимся? Наверное, та самая атмосфера, которая заставляет забыть о времени. Когда вы заходите на RUVIDEO, чтобы посмотреть онлайн «File class in java in hindi», вы рассчитываете на нечто большее, чем просто загрузку плеера. И мы это понимаем. Контент такого уровня заслуживает того, чтобы его смотрели в HD 1080, без дрожания картинки и бесконечного буферизации.
Честно говоря, Rutube сегодня — это кладезь уникальных находок, которые часто теряются в общем шуме. Мы же вытаскиваем на поверхность самое интересное. Будь то динамичный экшн, глубокий разбор темы от любимого автора или просто уютное видео для настроения — всё это доступно здесь бесплатно и без лишних формальностей. Никаких «заполните анкету, чтобы продолжить». Только вы, ваш экран и качественный поток.
Если вас зацепило это видео, не забудьте взглянуть на похожие материалы в блоке справа. Мы откалибровали наши алгоритмы так, чтобы они подбирали контент не просто «по тегам», а по настроению и смыслу. Ведь в конечном итоге, онлайн-кинотеатр — это не склад файлов, а место, где каждый вечер можно найти свою историю. Приятного вам отдыха на RUVIDEO!
Видео взято из открытых источников Rutube. Если вы правообладатель, обратитесь к первоисточнику.