All right, so let's break down this code once again, like we did for the Java language binding and
how we understood in the Java script and in the typescript language binding, you can see that in the
playwright, the create async method.
It's going to be pretty much like playwrite create a method that we used in our Java language binding.
That's exactly what it is in the C sharp as well.
So that's what this particular line of code is going to do for you.
And then we need to launch the playwright's browser like this.
I mean, once again, if you hit the dart or here, you can see that it brings you up the different
properties like chromium, Devizes, Firefox and Selector Web.
So this is the same property that was there, even for the Java and farther JavaScript and descript
language binding, which is pretty much exactly the same thing.
So no change on that.
And the launch here, I mean, you can see that for every method there is this suffix of async because
this is an asynchronous method.
So always the author tried to put a..
And this is the only thing which was not there in the Java.
Like, you don't really have to write and wait.
And I think that was something which I really like on the Java language binding.
But here in C Sharp, it looks a bit weird to write this in asynchronous mode, but because this is
a synchronous code, you can run this in parallel pretty easily.
I mean, that is the other major benefit of it.
But other than that, the only nagging thing is like you could write this code as if like a JavaScript
based code, even in the C sharp language, which is the only thing with this which looks like different
for that Java language binding versus C sharp language binding.
But other than that, they are pretty much exactly the same thing.
I mean, you launched the browser using the launch method and then there's this browser context.
As you can see here, we're going to get the play radar devices, the device over here.
And there is a method to browser context options.
So you are converting it to a context option, using this to context, option, method.
So this way it's going to be a context, basically.
And then you can set the local geo location, permissions and things of that nature and you can do all
sorts of things over here as well, which is quite good.
And this false method actually tells that you are going to launch this in a headless mode or helpful
more or something like that.
So you can see that if it is false, then basically it is going to be an headful mode.
And if you don't set anything, it's going to be an hitless model, something like that.
Other than that, that there is no change at the moment on this particular line of code and the rest
of code is going to be, again, straightforward and understandable.
You're going to set the new context, I think.
So basically, you are setting what context you're going to be using, like the browser context.
You're setting the new context option where you need to parse the context options and then you're going
to be open a new page and then you're going to be navigating like go to the page, click, I think,
and take a screenshot.
And if you hit Dart, let's say there is a film, you can see that there is a film set input file or
something like that.
So all those method names remains the same, except all the methods will get and I think suffix on their
name.
So other than that, they all look pretty much exactly the same, does exactly the same, and there
is no difference on that.
So having a clear understanding for us in playwrite with JavaScript language binding or types of language
binding will eventually give you a good idea on Java that we worked on the earlier section and in C
Sharp is going to be exactly the same thing.
So that's pretty cool to see.
That is going to be exactly all the same things.
I mean, same classes, same interfaces, all remains the same over here.
And if you want to set the launch options, you can set the launch options as well.
And similarly, if you want to write like a framework, you can easily do that as well.
Those things all remains pretty much exactly the same, like how we discussed on the Java language binding
on this language, binding as well.