Core Java With OCJP/SCJP-java IO Package-Part 2 || File I/O

Durga Software Solutions
26 Jun 201520:17

Summary

TLDRThe video script discusses the creation of files and directories in a programming context, likely Java, with a focus on constructors and file handling. It explains different constructors for representing resources in the current working directory and how to create files with specific names in designated folders. The script covers the essentials of file path handling, escape characters, and the importance of correct directory references to ensure successful file operations, aiming to clarify these concepts for students or developers.

Takeaways

  • 😀 The script discusses how to create a file and directory in a basic introduction, covering the terminology and various constructors present in the file class.
  • 👉 It explains the use of constructors in the file class with attention to careful observation of file and directory naming conventions.
  • 📂 The script covers the creation of a file with a specific extension, such as '.txt', and the importance of the directory name being a string.
  • 🔍 It mentions the requirement of creating a file with an absolute path and working directory, emphasizing the use of constructors to represent resources in the current working directory.
  • 🛠️ The script introduces the use of constructors to create a Java file object to represent the name of the file directory, presenting in the current working directory.
  • 📝 It explains the use of constructors for creating file names with '.txt' extensions in different folders, including the root directory.
  • 🗂️ The script discusses the use of constructors for representing resources in a specified subdirectory, highlighting the need to specify the directory in the constructor.
  • 🔑 The script touches on the importance of understanding how many constructors are used in the file class and how to use them effectively.
  • 📁 It explains the process of creating a directory with a specific name in the current working directory and the syntax involved in this operation.
  • 🔄 The script mentions the use of constructors for creating files and directories in a specified location, including the use of escape characters in file paths.
  • 📝 Lastly, the script emphasizes the need for clarity in code to avoid confusion and the importance of understanding file and directory creation for developers.

Q & A

  • What is the basic introduction about creating a file and directory in the script?

    -The script begins with an introduction to creating a file and directory, explaining the basic terminology and the importance of constructors in representing resources in the current working directory.

  • What are the different constructors mentioned in the script for creating files?

    -The script mentions three different constructors for creating files: the first constructor for representing resources in the current working directory, the second constructor for representing resources in a specified location, and the third constructor for creating a file with a specified name in the current working directory.

  • How can one create a file with a specific name in the current working directory as per the script?

    -According to the script, to create a file with a specific name in the current working directory, one can use the first constructor of the file class, which takes the file name as an argument.

  • What is the purpose of using the second constructor for creating files as discussed in the script?

    -The second constructor is used for representing resources in a specified location other than the current working directory, which is useful when the file needs to be created in a different directory.

  • How does the script explain the process of creating a directory?

    -The script explains that to create a directory, one can use the directory constructor, which requires the directory name and ensures that the directory is created in the current working directory.

  • What are the requirements for creating a file with an extension in the current working directory?

    -The script states that to create a file with an extension in the current working directory, one must specify the file name with the desired extension, such as '.txt', and use the appropriate constructor of the file class.

  • How can one create a file with a specific name in a directory that is not in the current working directory?

    -The script suggests using the second constructor of the file class, which allows specifying the path to the directory where the file should be created, along with the file name.

  • What is the significance of the third constructor mentioned in the script for file creation?

    -The third constructor is significant as it simplifies the process of creating a file by allowing the user to specify the file name directly, with the file being created in the current working directory without needing to specify the path.

  • What are the implications of using the backslash in file paths as discussed in the script?

    -The script mentions that the backslash is treated as an escape character in file paths, and to use it literally, one must use a double backslash. This is important for avoiding errors when specifying file paths.

  • How does the script address the issue of creating files and directories in a system that may not support certain file paths?

    -The script suggests that if a system does not support certain file paths, one should use the appropriate constructor that does not require specifying the directory name, or use the current working directory as a default.

  • What is the script's advice on handling file paths that include spaces or special characters?

    -The script advises that when dealing with file paths that include spaces or special characters, one should use the correct escape sequences or consider using the file class constructors that handle such paths automatically.

Outlines

00:00

📁 Introduction to File Constructors

The first paragraph discusses the basics of creating files and directories, focusing on the various constructors present in the file class. It explains the simple terminology and the three constructors available for creating files and directories in the current working directory. The paragraph also touches on how to represent resources in the current working directory using these constructors.

05:00

🔧 Using File Constructors with Examples

This paragraph provides detailed examples of using file constructors. It describes scenarios where a file or directory needs to be created in different locations, not just the current working directory. The paragraph explains how to specify subdirectories and file names using the constructors and highlights the importance of understanding different constructors through examples.

10:04

📂 Creating Files and Directories in Specific Locations

The third paragraph elaborates on creating files and directories in specified locations. It gives code examples for creating a directory named 'Durga Tooth' and a file within it. The paragraph emphasizes the steps to use different constructors for representing file names and directories in other specified locations.

15:07

💻 Handling Paths and Escape Characters in File Creation

This paragraph focuses on handling file paths and escape characters when creating files and directories. It explains the use of double backslashes to avoid compiler errors and provides an example of creating a file in a specific folder. The paragraph also shares a real-life incident where a student faced issues due to missing directories and emphasizes the importance of ensuring directory existence before running the code.

Mindmap

Keywords

💡File

A 'File' in the context of the video script refers to a digital container for storing information or data. It is a fundamental concept in computing, and the script discusses creating and working with files. For example, the script mentions 'create a file' and 'new file of string', indicating the process of file creation and the type of data it can hold.

💡Directory

A 'Directory' is a folder-like structure in a file system that organizes and stores files and other directories. The script discusses creating directories and working with them, such as 'create directory name with current working directory', which is essential for file organization and access.

💡Constructor

In programming, a 'Constructor' is a special method used to initialize objects. The script mentions 'constructors' in the context of creating file objects, such as 'File constructor' and 'new file object', which are used to set up and define the properties of a file.

💡Path

A 'Path' in computing refers to the location of a file or directory within a file system. The script discusses 'file path' and 'directory path', which are crucial for navigating and accessing files and directories within the system.

💡Working Directory

The 'Working Directory' is the current directory that the system is focused on for executing commands or accessing files. The script mentions 'current working directory' in the context of creating files and directories, which is the base location for these operations.

💡String

A 'String' in programming is a sequence of characters used to represent text. The script refers to 'string' when discussing the content of a file, such as 'new file of string', indicating that the file contains textual data.

💡Resource

In the context of computing, a 'Resource' refers to any system component or data that can be utilized by a program. The script mentions 'resources' in relation to file and directory creation, emphasizing the management of system assets.

💡Class

A 'Class' in object-oriented programming is a blueprint for creating objects. The script mentions 'class constructors', which are methods that create instances of a class, and 'file class', which is a template for file objects.

💡Create

The term 'Create' in the script refers to the action of generating new files or directories. It is a central action discussed in the script, such as 'create a file' and 'create directory', which are essential operations in file management.

💡Exception

An 'Exception' in programming is an event that occurs during the execution of a program that disrupts the normal flow of instructions. The script mentions handling exceptions, such as 'catch exception', which is important for error management in file operations.

💡Access

In the context of the script, 'Access' refers to the ability to interact with files or directories. It discusses 'accessing' files and directories, which is necessary for reading, writing, or modifying data.

Highlights

Introduction to creating a file and directory using basic constructors in Java.

Explanation of different constructors present in the File class for representing resources in the current working directory.

How to create a file with a specific name and extension using the File constructor.

Creating a directory with a specified name in the current working directory.

Using constructors to represent resources in a specified location other than the current working directory.

Differences between the constructors and their uses explained with examples.

Creating a Java file object to represent the name of the file and directory in the current working directory.

Understanding the requirements for creating a file with a .txt extension in a specific directory.

Demonstration of creating a file and directory in a subfolder within the current working directory.

How to use the first constructor for representing resources in the current working directory without any path.

Using the second constructor to represent resources in a specified absolute or relative location.

Explanation of the third constructor for creating a file with a specified name and extension in a specified directory.

Clarification on how to use constructors to automate the creation of files and directories in Java.

The importance of using the correct constructor based on the requirements for file and directory creation.

Handling file paths and the significance of using escape characters for special symbols in file names.

Demonstration of creating a file with a complex name involving spaces and special characters.

Summary of the three constructors and their applications in file and directory creation in Java.

Transcripts

play00:23

सो अप टू दिस जस्ट वी हैड टॉक अबाउट हाउ

play00:27

टू क्रिएट ए फाइल हाउ व कैन क्रिएट

play00:30

डायरेक्टरी लाइक द बेसिक इंट्रोडक्शन वी

play00:33

कवर्ड राइट नाउ आई विल एक्सप्लेन व्ट आर

play00:36

वेरियस कंस्ट्रक्टर्स प्रेजेंट इन फाइल

play00:39

क्लास हियर जस्ट ऑब्जर्व केयरफुली सर फाइल

play00:44

क्लास कंस्ट्रक्टर्स व्ट आर वेरियस

play00:49

कंस्ट्रक्टर्स आर देयर इन द फाइल क्लास

play00:52

वेरी सिंपल टर्मिनोलॉजी हाउ मेनी

play00:54

कंस्ट्रक्टर्स आर देयर थ्री कंस्ट्रक्टर्स

play00:56

टंग वेरी सिंपल जस्ट ब्जर्व व ऑलरेडी यूज

play01:01

दिस वन र जस्ट ब्जर्व फाइल ए इ इक्वल टू

play01:07

न्यू फाइल ऑफ फ इ फाइल ऑफ स्ट्रिंग

play01:13

स्ट्रिंग

play01:15

नेम इट मे बी अ फाइल नेम और इट मे बी

play01:18

डायरेक्टरी नेम सर सम टाइम्स माय

play01:21

रिक्वायरमेंट इज आई वांट टू क्रिएट अ फाइल

play01:25

नेम विथ ए बी सटी एक्सटी इन करेंट वर्किंग

play01:29

डायरेक्टरी

play01:31

और आई वांट टू क्रिएट डायरेक्टरी नेम विथ

play01:33

दुर्गा टूथ इन करंट वर्किंग डायरेक्टरी च

play01:38

कंस्ट्रक्टर वी हैव टू यूज दिस इ द

play01:40

कंस्ट्रक्टर वी हैव टू यूज आर य गेटिंग टू

play01:43

क्रिएट ए फाइल र डायरेक्टरी इन करेंट

play01:47

वर्किंग डायरेक्टरी च कंस्ट्रक्टर वी हैव

play01:50

टू यूज दिस इज मेंट फॉर टू

play01:54

रिप्रेजेंट टू रिप्रेजेंट

play01:57

रिसोर्सेस सर टू रिप्रेजेंट

play02:00

रिसोर्सेस इन करेंट वर्किंग डायरेक्टरी टू

play02:04

रिप्रेजेंट रिसोर्सेस इन करेंट वर्किंग

play02:07

डायरेक्टरी आई वांट टू क्रिएट ए फाइल

play02:10

क्रिएट ए जावा फाइल ऑब्जेक्ट टू

play02:12

रिप्रेजेंट नेम ऑफ द फाइल डायरेक्टरी

play02:15

प्रेजेंट इन करंट वर्किंग डायरेक्टरी देन

play02:18

वी हैव टू यूज दिस कंस्ट्रक्टर इज इट

play02:21

क्लियर बट हाउ टू यूज दिस कंस्ट्रक्टर्स

play02:23

आई विल एक्सप्लेन विथ एग्जांपल्स नॉट

play02:25

रिक्वायर्ड टू वरी एट ऑल जस्ट ऑब्जर्व लेट

play02:27

मी लिस्ट आउट सेकंड कंस्ट्रक्टर आल्सो

play02:30

समटाइम माय रिक्वायरमेंट इ कैन यू प्लीज

play02:33

क्रिएट फाइल नेम विथ एी सड एक्स

play02:38

इन दुर्गा टूथ फोल्डर र इन एक्सवा ज

play02:43

फोल्डर सम अदर लोकेशन नॉट इन करंट वर्किंग

play02:46

डायरेक्टरी देन च कंस्ट्रक्टर वी हैव टू

play02:49

यूज जस्ट ब्जर्व दिस वन कैन यू प्लीज

play02:51

क्रिएट डायरेक्टरी कैन यू प्लीज क्रिएट

play02:54

फाइल नेम विथ ए बी सड एक्स कैन यू प्लीज

play02:59

क्रिएट ए फाइल नेम विथ ए बी सीड एक्सटी इन

play03:03

इन दुर्गा टूथ फोल्डर इन दुर्गा टूथ

play03:07

फोल्डर हाउ यू कैन इन दुर्गा टूथ ए बी सड

play03:12

एक्स इज माय रिक्वायरमेंट हैव य अब राइट

play03:14

देन फाइल ए इ इक्वल टू न्यू फाइल आ इन च

play03:21

सब डायरेक्टरी यू रिक्वायर्ड दुर्गा

play03:25

टूथ इन द व्ट फलम यू रिक्वायर ए बी सीड t

play03:33

एक्टी आर गेटिंग ए सड एक्सटी सर इन दिस सब

play03:38

डायरेक्टरी आई वांट टू क्रिएट फाइल नेड

play03:40

विथ वन ए बी सड एक् सर दुर्गा टूथ इज देयर

play03:44

ओके इन द आई वांट टू क्रिएट ए फाइल ए बी

play03:48

सीटी एकटे दैट इज आर य गेटिंग इफ यू वांट

play03:53

टू क्रिएट ए फाइल र डायरेक्टरी प्रेजेंट

play03:56

इन सम अदर डायरेक्टरी र इन सम अदर

play03:58

डायरेक्टरी देन व कंस्ट्रक्टर वी हैव टू

play04:01

यूज इ फाइल ए इ टू न्यू फाइल ऑफ फ इ फाइल

play04:09

ऑफ स्ट्रिंग स्ट्रिंग सब डीआई आर सर

play04:14

स्ट्रिंग सब डीआई आर नेम सर इन वच

play04:17

डायरेक्टरी मे बी दुर्गा टूथ मे बी लन मे

play04:20

बी सी क्लन ला हियर यू हैव टू स्पेसिफाई

play04:22

इन चच डायरेक्टरी यू रिक्वायर च फाइल और च

play04:27

डायरेक्टरी आर यू गेटिंग स्ट्रिंग

play04:30

नेम आर य गेटिंग राट सर दिस इ द

play04:34

कंस्ट्रक्टर टू रिप्रेजेंट क्रिएट जावा

play04:37

फाइल ऑब्जेक्ट टू रिप्रेजेंट नेम ऑफ द

play04:40

फाइल डायरेक्टरी प्रेजेंट इन सम अदर सब

play04:43

डायरेक्टरी र स्पेसिफाइड सब डायरेक्टरी

play04:46

दिस इ द सेकंड कंस्ट्रक्टर व हैव आर यल ट

play04:49

अंडर ओके लाइक थर्ड कंस्ट्रक्टर सर न

play04:53

केयरफुली हाउ टू यूज कंस्ट्रक्ट आ वि

play04:55

एक्सप्लेन विथ एपल नट य वय इफ यू आर सी

play05:00

देन यू कैन एबल टू गेट मच क्टी स सर र

play05:03

जस्ट बव जस्ट ई कवर फ इ न्यू फाइल ऑफ

play05:09

इनसाइड दुर्गा टूथ आई वां रिपेंट ए बी सड

play05:13

एक्सम दिस दुर्गा टूथ ऑलरेडी पॉइंटेड बाय

play05:17

ए1 बी बिकॉज इट डायरेक्टरी डायरेक्टरी कैन

play05:21

बी पॉइंटेड बा फाइल ऑब्जेक्ट र न यस ट्स व

play05:25

फाइल ए इ टू न्यू फाइल आ

play05:30

इंस्टेड ऑफ स्पेसिफाई डायरेक्टरी नेम नाउ

play05:33

द करेस्पॉन्डिंग्ली

play05:36

[संगीत]

play05:48

वन सर फाइल ए इ ट न्यू फाइल ऑफ फ नू फाइल

play05:56

ऑफ स्ट्रिंग सब सर इफ दिस सब डायरेक्टरी

play06:01

ऑलरेडी पॉइंटेड बाय सम फाइल रिफरेंस देन

play06:05

हैव य बज फाइल सब डीआई आर कमा स्ट्रिंग

play06:12

नेम आर य गेटिंग फाइल सब डीआई आर कमा

play06:15

स्ट्रिंग नेम हैव यू ब्जर्व स टोटल हाउ

play06:18

मेनी कंस्ट्रक्टर्स आर देयर थ्री

play06:20

कंस्ट्रक्टर फर्स्ट कंस्ट्रक्टर मेंट फर

play06:24

रिप्रेजेंटिंग रिसोर्सेस प्रेजेंट इन करंट

play06:26

वर्किंग डायरेक्टरी नेक्स्ट टू

play06:29

कंस्ट्रक्टर्स मेंट अप फॉर रिप्रेजेंटिंग

play06:32

रिसोर्सेस प्रेजेंट इन सम अदर लोकेशन सम

play06:35

अदर स्पेसिफाइड सब डीआर ओके लाइक सर जस्ट

play06:39

अवेयर हाउ मेनी कंस्ट्रक्टर्स आर देयर बट

play06:43

इवन यू आर नॉट गेटिंग वंस इफ यू आर सीइंग

play06:45

द एग्जांपल देन यू कैन एबल टू गेट आर यू

play06:48

गेटिंग राइट सर एज ऑफ नाउ अप टू दिस हाउ

play06:50

मेनी कंस्ट्रक्टर्स आर देयर इन द फाइल

play06:52

क्लास थ्री कंस्ट्रक्टर मीन थ्री

play06:54

कंस्ट्रक्टर फर्स्ट कंस्ट्रक्टर मेंट फॉर

play06:56

रिप्रेजेंट रिसोर्सेस प्रेजेंट इन इ साइ

play07:00

करंट वर्किंग डायरेक्टरी नेक्स्ट टू

play07:02

कंस्ट्रक्टर मेंट अप फॉर रिप्रेजेंटिंग

play07:04

रिसोर्सेस प्रेजेंट इन सम अदर लोकेशन जस्ट

play07:08

अप टूट अवेयर बट हाउ यू कैन यूज दिस

play07:11

कंस्ट्रक्टर विथ एग्जांपल आई विल

play07:12

एक्सप्लेन सोट यू पीपल कैन अवेयर क्लियर

play07:15

राट स जस्ट ब्जर्व माय टारगेट इ हाउ टू

play07:19

यूज दिस कंस्ट्रक्टर्स इ इफ आई स्टार्ट

play07:22

एक्सप्लेनिंग विथ एग्जांपल देन यू विल गेट

play07:24

मच क्लेरिटी जस्ट मा मा माय रिक्वायरमेंट

play07:27

play07:28

ब्जर्व राइट कोड सर कैन यू प्लीज कैन यू

play07:32

प्लीज राइट राइट कोड टू क्रिएट राइट कोड

play07:38

टू क्रिएट ए फाइल टू क्रिएट ए फाइल नेड

play07:43

विथ राइट कोड टू क्रिएट ए फाइल नेड विथ ो

play07:48

डटी एक्सटी इन करेंट वर्किंग डायरेक्टरी

play07:53

आर य गेटिंग सर अब्ज आई वांट टू क्रिएट

play07:56

राइट कोन टू क्रिएट ए फाइल नेम विथ ो

play08:00

एक्सटी इन करेंट वर्किंग डायरेक्टरी सर

play08:04

विथ दिस नॉलेज कैन यू प्लीज टेल व्च

play08:07

कंस्ट्रक्टर वी हैव टू यूज ओबवियसली करंट

play08:10

वर्किंग डायरेक्टरी रिसोर्सेस इज नथिंग बट

play08:12

वच कंस्ट्रक्टर वी हैव टू यूज फर्स्ट

play08:14

कंस्ट्रक्टर सर हाउ टू यूज जस्ट ब्जर्व

play08:18

फाइल य यू नो दिस कोड फाइल f इ इक्वल टू

play08:23

न्यू फाइल ऑफ फइल इ न्यू फाइल ऑफ यर फाइल

play08:27

इ न्यू फाइल न्यू फाइल ऑ यर ए डेमो डॉट टी

play08:34

एक्सटी जस्ट क्रिएट जावा फाइल ऑब्जेक्ट

play08:38

एंड देन क्रिएट द फिजिकल फाइल एफ डॉट एफ

play08:43

डॉट क्रिएट न्यू फाइल आ गेटिंग एडॉट

play08:48

क्रिएट न्यू फाइल नाउ ब्जर्व दिस वन सर यर

play08:52

सॉरी यर जस्ट ब्जर्व दिस वन इन द करेंट

play08:56

वर्किंग डायरेक्टरी देर इज अ फाइल नेड विथ

play09:00

व्ट ो एक बाय डिफॉल्ट वी कैन एबल टू

play09:03

क्रिएट आई होप यू पीपल कैन अवे सर इन दिस

play09:06

एग्जांपल व्हिच कंस्ट्रक्टर वी आर यूजिंग

play09:09

सर ओके वी आर यूजिंग फर्स्ट कंस्ट्रक्टर

play09:11

नाउ हाउ टू यूज अ फर्स्ट कंस्ट्रक्टर नॉट

play09:15

रिक्वायर्ड टू कीप एनी एक्सप्लेनेशन सर

play09:17

सिंपल क्रिएट अ फाइल नेम विथ रिमो इन द

play09:20

करंट वर्किंग डायरेक्टरी क्रिएट अ फाइल

play09:22

ऑब्जेक्ट फाइल f इ इ न्यू फाइ ऑफो . t

play09:24

एकटी एडॉट क्रिएट न्यू फाइल ऑटोमेटिक द

play09:27

फाइल गट

play09:29

क्लियर फर

play09:30

ल सर आई विल गो फॉर सेकंड एग्जांपल आई नो

play09:34

यू कैन अवे दिस वन आई कैन गो फॉर सेकंड

play09:36

एग्जांपल वेर हाउ टू यूज सेकंड एंड थर्ड

play09:41

कंस्ट्रक्टर सर सर जस्ट

play09:43

ब्जर्व माय रिक्वायरमेंट

play09:46

इ आई वांट टू क्रिएट आई वांट टू क्रिएट ए

play09:52

डायरेक्टरी नेम विथ दुर्गा ूथ इन करंट

play09:57

वर्किंग डायरेक्टरी ज बर्स आई वा टू

play09:59

क्रिएट ए डायरेक्टरी नेम विथ दुर्गा टूथ

play10:03

इन करेंट वर्किंग

play10:05

डायरेक्टरी इन ट डायरेक्टरी आई हैव टू

play10:09

क्रिएट फाइल नेम विथ ए बी सड एक्सटी सर यर

play10:14

कोड एग्जांपल टू सर जस्ट ब्जर्व

play10:18

कोड टू क्रिएट ए डायरेक्टरी हा क्रिएट

play10:24

डायरेक्टरी नेम विथ राइट को टू क्रिएट

play10:28

डायरेक्टरी नेम वि व्ट इ द नेम सर दुर्गा

play10:33

टूथ इन इन करेंट वर्किंग डायरेक्टरी सर

play10:38

कैन य प्लीज क्रिएट राइट कोड टू क्रिएट

play10:41

डायरेक्टरी नेम विथ दुर्गा टूथ इन करेंट

play10:45

वर्किंग डायरेक्टरी अंड

play10:48

अंड क्रिएट ए फाइल अंड क्रिएट ए फाइल नेम

play10:55

विथ क्रिएट फाइल नेम विथ ए ब सी डटी

play11:00

एक्सटी ए बी सड एक्सटी इन ट

play11:05

डायरेक्टरी इन ट दुर्गा थ लाइक सर दिस इ

play11:10

माय प्रॉब्लम स्टेटमेंट सर वाट टू क्रिएट

play11:13

डायरेक्टरी नेम विथ दुर्गा थ इन करेंट

play11:17

वर्किंग डायरेक्टरी एंड क्रिएट फाइल नेम

play11:20

वि ए बी सीस इन

play11:23

डायरेक्टरी फ फ लेट कंसंट्रेट अबाउट अप टू

play11:29

डायरेक्टरी सर क्रिएट डायरेक्टरी नेम वि

play11:32

दुर्गा थ इन करेंट वर्किंग डायरेक्टरी

play11:36

फाइल ए

play11:38

इक्ट न्यू फाइल

play11:40

ऑफ इ फाइल फर्स्ट कंस्ट्रक्टर सर व हैव टू

play11:45

क्रिएट डायरेक्टरी इन करेंट वर्किंग

play11:47

डायरेक्टरी वट इ द कंस्ट्रक्टर दुर्गा

play11:51

टूथ ला फ फ दुर्गा थ नाउ सर र कैन यू

play11:58

प्लीज क्रिएट

play12:00

एड एम केडी आई आर आट सर नाउ र यनो व

play12:09

क्रिएटेडटेड

play12:11

डायरेक्टरी नेम विथ दुर्गा ूथ

play12:15

ए रेफरेंस पॉइंट नटू द सर अप टू दिस च

play12:21

कक्टर यू सर फस्ट कक्टर ना मा

play12:25

रिक्वायरमेंट इन डायरेक्टरी आई हैव टू

play12:29

क्रिएट ए फाइल नेम विथ ए बी सीड एक्स आई

play12:35

हैव टू क्रिएट ए फाइल नेम विथ ए बी सीटी

play12:39

एक्सटी ट्स माय रिक्वायरमेंट व्ट कोड वी

play12:43

हैव टू राइट ब्जर्व दिस वन सर फाइल f1 इ

play12:48

इक्व टू न्यू फाइल ऑफ न्यू फाइल ऑफ सर ए स

play12:54

एक हैव टू क्रिएट इन दुर्गा 13 ट्स वाइ

play12:59

दुर्गा

play13:01

टूथ कामा दुर्गा टूथ कामा इन द ए बी सी

play13:07

डटी

play13:10

एक्सटी दुर्गा

play13:12

थमा ए बी सीड एक्स इन दुर्गा कैन यू प्लीज

play13:17

क्रिएट फाइल नेम वि ए बी स माय

play13:20

रिक्वायरमेंट सर च कंस्ट्रक्टर यू सेकंड

play13:23

कंस्ट्रक्टर हाउ ट य सेकंड कंस्ट्रक्टर

play13:25

नाउ य शड फैमिलियर नेक्स्ट लेट मी कमेंट

play13:29

दिस वन सेम लाइन वी कैन राइट इन अदर

play13:33

स्टाइल आल्सो फाइल एव इक्वल

play13:37

टू न्यू फाइल ऑफ फ इ ू फाइल दुर्गा टूथ

play13:42

ऑलरेडी पॉइंटेड बाय फ ट्स वा ए कामा

play13:47

दुर्गा टूथ लडी पॉइंटेड बा ए

play13:50

एमा ए बी

play13:52

सीड एक्स आ गेटिंग ए बी सी डटी एक्सटी नाउ

play13:59

व डॉट सर च कंस्ट्रक्टर यूज थर्ड

play14:02

कंस्ट्रक्टर हाउ टू यूज फर्स्ट

play14:04

कंस्ट्रक्टर हाउ टू यूज सेकंड कंस्ट्रक्टर

play14:06

हाउ टू यू थड कंस्ट्रक्टर यू नो एव ड

play14:11

क्रिएट न्यू

play14:13

फाइल एव क्रिएट न्यू फाइल एव पॉइंट दिस वन

play14:21

आर यबल ू अंडरस्टैंड राट सर राइट कोड टू

play14:24

क्रिएट डायरेक्टरी नेम विथ दुर्गा टूथ इन

play14:28

करेंट वर्किंग डायरेक्टरी इन द कैन यू

play14:32

प्लीज क्रिएट ए फाइल नेम विथ एबीसी एक्सटी

play14:35

इन दैट डायरेक्टरी इ नथि नथिंग इ देर दिस

play14:40

इज द थिंग हाउ वी कैन क्रिएट ए डायरेक्टरी

play14:42

हाउ वी कैन क्रिएट ए फाइल इन द डायरेक्टरी

play14:45

इज इट क्लियर फॉर ल ऑफ य राइट सर इन द

play14:47

फाइल क्लास टोटल हाउ मेनी कंस्ट्रक्टर्स

play14:50

आर देयर थ्री कंस्ट्रक्टर हाउ टू यूज दज

play14:53

थ्री कंस्ट्रक्टर बेस्ट एग्जांपल जस्ट

play14:55

रिव्यू वंस अगेन ऑटोमेटिक विल गेट मच क्ल

play14:59

इ क्लियर सर लेट गो फॉर न मोर एग्जांपल

play15:02

एटली सोट यू विल गेट मोर मोर कंफर्ट यर सी

play15:07

आई वांट टू क्रिएट फाइल नेम विथ ो डटी

play15:12

एक्स आ गेटिंग आई वांट टू क्रिएट फाइल नेम

play15:16

विथ ो डटी एक्सटी इन इन

play15:21

लन एक्स वाई जड फोल्डर इन ई कलम एक्स वा

play15:26

जड फोल्डर आई वाट टू क्रिएट नेड विथ मोटी

play15:30

एक्स इज माय रिक्वायरमेंट सर व्ट इज माय

play15:33

प्रॉब्लम स्टेटमेंट

play15:35

कोड टू क्रिएट टू क्रिएट ए फाइल फाइल नेम

play15:42

विथ को टू क्रिएट ए फाइल नेम विथ डेमो डटी

play15:48

एक्टी डेमो एक्स इन इ कोलन लन एक्स वा जड

play15:56

फोल्डर लन ज फोल्डर लाइक दिस इज माय

play16:01

रिक्वायरमेंट री सिंपल सर वट ट वे यर जस्ट

play16:06

ब्जर्व फाइल ए इ इक्वल टू न्यू फाइल ऑफ लन

play16:12

एक्सवा ज सर

play16:16

इनसाइड कोलन एक्स वा जड सर ब बट केयरफुली

play16:22

र आम यूजिंग डबल बैकल ब द रीजन इफ आई कैन

play16:27

यूज नर्मल ब

play16:29

एक् वेयर एवर बैसल सिंबल इज देयर कंपाइलर

play16:32

इज ऑलवेज गोइंग टू ट्रीट अ एस्केप

play16:35

कैरेक्टर कंपाइलर डोंट ट्रीट दिस वन एज

play16:38

एस्केप कैरेक्टर बैक स्लैश कैन यू प्लीज

play16:41

कंसीडर बैक स्लैश सिंबल ओनली हाउ यू कैन

play16:44

यर लाइक अनदर बैक स्लैश मेक शर सर व्हेन

play16:47

एवर वी आर यूजिंग बैक स्लैश एज ए सिंबल

play16:49

रिलेटेड टू फाइल पाथ कंपल्सरी वी शुड स्लश

play16:53

अदर वाइ कंपल इज गोइंग टू ट्रीट एस्केप

play16:55

कैरेक्टर देर इ नो एस्केप कैरेक्टर नेम

play16:57

विथ बैक स्लैश

play16:59

इलीगल एस्केप कैरेक्टर लाइक यू मेट कंपर

play17:01

ट्स व मेक शर यू शुड यूज डबल बैक स्लश एंड

play17:05

देन इन द व्ट इज द नेम सर डेमो डटी एक्सटी

play17:11

आर गेटिंग द पॉइंट ओके सर फाइल ए इ न्यू

play17:15

फाइफ सर इन न एक्सवा ज कैन यू प्लीज

play17:19

रिप्रेजेंट डेमो एक्टी सर आई वांट टू

play17:23

क्रिएट दैट फाइल क्रिएट न्यू फाइल्स

play17:29

क्रिएट न्यू फाइल लाइक ब्जर्व दैट वन सर र

play17:32

ड य नो

play17:34

लन इन द एक्स वाई जड फोल्डर इज देयर इन द

play17:40

डेमो डॉटी एक्स बा डिफॉल्ट विल बी

play17:57

क्रिएटेड्रॉअर्नेविगेटर व कैन क्रिएट फाइल

play17:59

हाउ यू कैन क्रिएट डायरेक्टरी इन द करेंट

play18:02

वर्किंग डायरेक्टरी और इन सम अदर लोकेशन

play18:05

जस आर द एग्जांपल व्ट य पीपल शर बट लेट

play18:08

एक्सप्लेन न स्मल फनी फनी थिंग ट हैपन विथ

play18:11

माय स्टूडेंट्स

play18:12

सर आई एक्सप्लेन दिस एग्जांपल देन पीपल

play18:16

वेंट आफ्टर टू और ी डेज वन स्टूडेंट केम

play18:20

बैक सर फ थड एग्जांपल इ नॉट वर्किंग सर

play18:25

लाइक अरे व्ट एग्जांपल ट य फेसि सर न

play18:30

एक्सवा ज कैन यू प्लीज क्रिएट फाइल नेम वि

play18:33

ोट एग्जांपल इ नॉट वर्किंग इन माय सिस्टम

play18:36

सर लाक आस्क देन आई टोल्ड ओके व्ट

play18:40

प्रॉब्लम यू आर गेटिंग आ आस्क देन ही

play18:42

टोल्ड सर फाइल न फ एक्सेप गेटिंग सरला देन

play18:47

इटली आस्क इन यवर सिस्टम न एक्सवा लडी देर

play18:52

न इटली पर्सन थ सर आईव ओली सींड

play18:57

ड्राइव इज नॉट देयर लाइक सर इफ इ क्लन

play19:00

एक्सवा जड फोल्डर इज नॉट देयर दिस

play19:02

प्रोग्राम वनट वर्क टुमारो यू मे आस्क वंस

play19:05

अगेन सर इट इज नॉट वर्किंग इन माय सिस्टम

play19:07

एज्यूम दैट इन यवर सिस्टम लन एक्सवा ज

play19:10

फोल्डर ऑलरेडी देयर देन ओनली दिस कोड इज

play19:13

गोइंग टू वर्क इज इट क्लियर फॉर ल ट्स ल

play19:16

दीज आर अबाउट व्हाट इ हाउ मेनी

play19:19

कंस्ट्रक्टर्स आर देयर इन द फाइल हाउ टू

play19:21

यूज दिस कंस्ट्रक्टर्स राइट एनी

play19:23

एक्सप्लेनेशन इज रिक्वायर्ड सर आई होप यू

play19:25

पीपल कैन गेट क्लीयरली ट ओके ट्स ऑल

play19:27

नेक्स्ट आफ्टर दिस सर वी

play19:31

क्रिएटेडटेड टू द फाइल हाउ यू कैन रीड सम

play19:35

डाटा फ्रॉम द फाइल फॉर द राइटर्स एंड

play19:38

रीडर्स वी हैव टू डिस्कस बट बिफोर द इज

play19:41

देर नी इंपॉर्टेंट मेथड्स प्रेजेंट इन

play19:43

फाइल क्लास अदर देन व्हाट एवर वी यूज दैट

play19:46

पाट आल्सो लेट मी टॉक इज़ इट क्लियर राइट

play19:57

ओके

play20:16

Rate This

5.0 / 5 (0 votes)

Related Tags
ProgrammingFile ManagementDirectory CreationConstructorsTechnical GuideCoding TutorialResource RepresentationCode ExamplesDeveloper ToolsSoftware Development