<commit_before>/*
 * Copyright 2014 Mozilla Foundation
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *totalMemory
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package flash.display {
import flash.filters.BitmapFilter;
import flash.geom.ColorTransform;
import flash.geom.Matrix;
import flash.geom.Point;
import flash.geom.Rectangle;
import flash.utils.ByteArray;

[native(cls='BitmapDataClass')]
public class BitmapData implements IBitmapDrawable {
  public native function BitmapData(width:int, height:int, transparent:Boolean = true, fillColor:uint = 4294967295);
  public native function get width():int;
  public native function get height():int;
  public native function get transparent():Boolean;
  public function get rect():Rectangle {
    return new Rectangle(0, 0, width, height);
  }
  public native function clone():BitmapData;
  public native function getPixel(x:int, y:int):uint;
  public native function getPixel32(x:int, y:int):uint;
  public native function setPixel(x:int, y:int, color:uint):void;
  public native function setPixel32(x:int, y:int, color:uint):void;
  public native function applyFilter(sourceBitmapData:BitmapData, sourceRect:Rectangle,
                                     destPoint:Point, filter:BitmapFilter):void;
  public native function colorTransform(rect:Rectangle, colorTransform:ColorTransform):void;
  public native function compare(otherBitmapData:BitmapData):Object;
  public native function copyChannel(sourceBitmapData:BitmapData, sourceRect:Rectangle,
                                     destPoint:Point, sourceChannel:uint, destChannel:uint):void;
  public native function copyPixels(sourceBitmapData:BitmapData, sourceRect:Rectangle,
                                    destPoint:Point, alphaBitmapData:BitmapData = null,<commit_msg>Port all traits of flash.display.BitmapData to TypeScript<commit_after>/*
 * Copyright 2014 Mozilla Foundation
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *totalMemory
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package flash.display {
import flash.filters.BitmapFilter;
import flash.geom.ColorTransform;
import flash.geom.Matrix;
import flash.geom.Point;
import flash.geom.Rectangle;
import flash.utils.ByteArray;

[native(cls='BitmapDataClass')]
public class BitmapData implements IBitmapDrawable {
  public native function BitmapData(width:int, height:int, transparent:Boolean = true, fillColor:uint = 4294967295);
  public native function get width():int;
  public native function get height():int;
  public native function get transparent():Boolean;
  public native function get rect():Rectangle;
  public native function clone():BitmapData;
  public native function getPixel(x:int, y:int):uint;
  public native function getPixel32(x:int, y:int):uint;
  public native function setPixel(x:int, y:int, color:uint):void;
  public native function setPixel32(x:int, y:int, color:uint):void;
  public native function applyFilter(sourceBitmapData:BitmapData, sourceRect:Rectangle,
                                     destPoint:Point, filter:BitmapFilter):void;
  public native function colorTransform(rect:Rectangle, colorTransform:ColorTransform):void;
  public native function compare(otherBitmapData:BitmapData):Object;
  public native function copyChannel(sourceBitmapData:BitmapData, sourceRect:Rectangle,
                                     destPoint:Point, sourceChannel:uint, destChannel:uint):void;
  public native function copyPixels(sourceBitmapData:BitmapData, sourceRect:Rectangle,
                                    destPoint:Point, alphaBitmapData:BitmapData = null,
{'fraction_non_alphanumeric': 0.08268676568388383, 'fraction_numerical': 0.01019729549988916, 'mean_word_length': 4.556650246305419, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1859637', 'n_tokens_mistral': 1177, 'n_tokens_neox': 1137, 'n_words': 392}