text
stringlengths
1
22.8M
The Reverend Arthur Dudley Stewart (史超域牧師) (1877–1948) was a British missionary to Hong Kong and the seventh principal of St. Paul's College, Hong Kong. Biography Arthur Dudley Stewart was born on 8 October 1877 in Fuzhou, China. His father, Rev. Robert Warren Stewart and his mother, Louisa Kathleen Stewart (née Smyly) were both members of well-known Dublin families. They had gone out to Fujian as C.M.S. missionaries in 1875. Arthur spent his early years in Fuzhou and spoke Fuzhou dialect before he learned to speak English. In 1882, the Stewarts went on furlough, and when they returned to China, Arthur and two young brothers were left in the care of their grandfather, Mr. J.R. Stewart of Gortletteragh, Dunlaoghaire. Here Arthur was brought up, except that, when his parents returned to furlough, he and the other children joined them in England and the family was reunited for a few months. Later the three boys went to Haileybury. When Arthur was sixteen, his parents returned to China for the fourth and last time, taking with them the five younger children – the Stewarts were indeed a large family. Then came the unfortunate tragedy of the uprising of the Chinese party, known to foreigners as ‘the vegetarians’ This was semi-political party, whose aim was mainly anti-government, but partly anti-foreign. This party had few, if any, branches outside the province of Fujian; and even there was not taken serious either by the authority or by the foreigners. All foreigners were called in to Fuzhou, but after a couple months the provincial governor declared that all trouble was over; and a number of missionaries left the city for a brief holiday. On 1 August 1895, a party of ‘Vegetarians’ attacked and killed fifteen including Mr and Mrs Stewart and two of their children. The event is known as Kucheng massacre. The tragedy of his parents’ death made a deep impression on Arthur. From an early age, he had determined the ministry with a possible view to later going out to the Mission Field; but the loss of his parents made him determined to carry on the work which had been interrupted by their untimely deaths. It would seem strongly that he influenced other members of his family, since four followed his examples at various times. In 1898, he entered Trinity College, Cambridge where he completed his university and theological training. He was ordained in 1901, becoming curate at St. Paul's Canonbury, North London. Four years later he was accepted as a candidate by the Church Missionary Society and sailed for Hong Kong, accompanied by a younger sister, Kathleen in November 1905. It would appear strange that Hong Kong should have been selected rather than Fukien, which had not only been the scene of his parents’ work, but also his early home. It seems that the Church Missionary Society at the time considered that there were great possibilities in Hong Kong and South China, which up to then had been somewhat neglected; while Fukien was comparatively well provided, principally by members of the Dublin University Mission, which had been founded and organised during his last furlough by Robert Stewart, who was himself a T.C.D. man. It was to Hong Kong consequently that Arthur Stewart was sent. After a preliminary period of language study, he was appointed to the Staff of St. Stephen's College- then in its infancy. Kathleen Stewart joined the staff of St. Stephen's Girls College, Hong Kong. The Chinese Church of Hong Kong was still in its initial stage, though Christian work of a sort had been carried on for nearly sixty years by that time. There was but one Chinese Church on the Hong Kong Island, St. Stephen's in Pokfulam Road. There was, however, a small but enthusiastic group of Chinese Christian scattered throughout the eastern part of the city, and under Stewart's leadership, these used to meet on Sundays in the small chapel in the basement of the Bishop's House. Many of these “catacomb Christians” came from beyond Happy Valley, facing a two-hour walk to attend the service and never missing. This congregation extended rapidly and after a year or two outgrew the church. Then services were held out of doors on what was then the Bishop's tennis court; in rainy weather the verandas were used. Meanwhile, the Parent Committee of the CMS had decided to close down the training school for Chinese catechists which had been started by the Rev. A. Bunbury in 1900, and carried on, by permission of the Bishop, in St. Paul's College, Hong Kong: this venture having proved unsuccessful. Bishop Lander then invited the C.M.S. to re-open and take charge of the former school which had been started in the early days of the Colony and had continued to exist spasmodically “by fits and starts” – it had been closed and re-opened at least three times. The C.M.S. gratefully accepted the offer and appointed Arthur as the Headmaster. In September 1909, St. Paul's College was re-opened, the staff compromising Stewart himself and Thomas Chan. Growth was rapid and further additions were made to the staff- Ho Wing-kin, Lam Tung, Fung Man-sui, Wei Wing-hon, Wei Wing-yuet, all former students of St. Stephen's College. The growth of the school coincided with the increase in numbers of the little band of Christmas in the Bishop's Chapel, and Rev. Stewart conceived the idea of satisfying two needs at the same time. By cutting away the side of the hill west of Glenealy it was possible to erect a building, with classrooms below and a church above. This was completed by the end of 1911, and thus St. Paul's Church came into being. For many years the Church was also used on weekdays as a school chapel. In its earlier years there was a service in English on Sunday evenings in St. Paul's Church for the benefit of those Chinese, returned students and the like, who now frequent St. John's Cathedral. Here Arthur Stewart was at his best. His fluent, eloquent sermons in simple English words which all could follow were the subject of keen discussion among students afterwards in every University Hostel. That handsome young Irishman with the graceful pulpit manner, the musical voice, the remarkable eyes and the amazing fluency of speech must be well remembered and loved by hundreds of men and women who heard him in those days, Hong Kong was a family then compared with its immensity today, rather less than half a million souls. Everyone knew Arthur, and he knew almost everyone. At Government House he was welcomed as warmly as at the Chinese Ladies Prayer Meetings, which have been such a remarkable feature of St. Paul's Church and of other Chinese churches throughout many years. For some years he continued the double role of Headmaster and Vicar of the parish. During those years, he School continued to grow. Branch schools of St. Paul's College, Hong Kong were formed in Hollywood Road, at Shau Kei Wan and Aberdeen, and in far off Rabaul, staffed in every case by Old Paulines. It is not possible to follow the careers of Arthur's student in details. Stewart carried on his work in Hong Kong for 28 years, for 21 of which he was the headmaster of St. Paul's College, Hong Kong. In 1930, he resigned from the headmaster of St. Paul's and in 1933 retired completely from work in Hong Kong. He then became vicar of Lyonsdown in New Barnet, London, in succession of his father-in-law, Bishop Gerald Heath Lander. A farewell meeting was given in the City Hall and was addressed by His Excellency the Governor, Sir William Peel. Fifteen years of successful work in England followed which was recalled by Bishop Sherwood Jones at the moving funeral held in Lyonsdown Church, London. References Fragrant Stream Wayfarer P.47-50, 1957 English edition External links St. Paul's College 1877 births 1948 deaths Alumni of Trinity College, Cambridge Principals of St. Paul's College, Hong Kong Christian missionaries in Hong Kong British missionaries People from Fuzhou
Bhupendrasinh is an Indian politician and was state Cabinet minister for Education (Primary, Secondary and Adult), Higher and Technical Education, Law and Justice, Legislative and Parliamentary affairs, Salt Industry, Cow-Breeding and Civil Aviation in the Second Vijay Rupani cabinet. On 12 May 2020, the Gujarat High Court declared that the 2017 election of Chudasama was invalid. The proceedings were stayed by the Supreme Court a few days later. References Year of birth missing (living people) Living people Place of birth missing (living people) Bharatiya Janata Party politicians from Gujarat Gujarat MLAs 2012–2017 Gujarat MLAs 2017–2022 State cabinet ministers of Gujarat
A–K Apple Jacks A step on the spot, with twisting foot and the weight on the heel, like this. Ball change Ball change is a movement where the dancer shifts the weight from the ball of one foot to the other and back. This is mostly used in jazz and jive. Basic (step / figure / movement / or pattern) A basic figure is the very basic step that defines the character of a dance. Often it is called just thus: "basic movement", "basic step" or the like. For some dances it is sufficient to know the basic step performed in different handholds and dance positions to enjoy it socially. Box step The box step is a dance figure named so because the steps rest in the four corners of a square. It is used, e.g., in American Style ballroom dances: rumba, waltz, bronze-level foxtrot. The leader begins with the left foot and proceeds as follows. First half-box: Forward-side-together Second half-box: Backwards-side-together Every step is with full weight transfer. During the second and fourth step it is advised the foot to travel along two sides of the box, rather than along its diagonal. Rhythm varies, e.g., it is "1-2-3,4-5-6" in Waltz and "slow quick quick, slow quick quick" in Rumba. Chaînés / chainé turns / chaines turns French for "chain", a series of quick turns starting from second position going to first position alternating on either flat feet or on relevé with progression along a straight line or circle. Chassé Chassé (French, "to chase") is a dance step with a triple step pattern used in many forms of dance. It is a gliding, flowing step with the feet essentially following a step–together–step pattern. Timing and length of steps vary from dance to dance. Closed change Closed change is a basic step in the waltz. The leader steps forward on either foot whilst the follower steps backward on the opposing foot (e.g.: the leader steps forward on their right foot whilst the follower steps back on their left). Both partners will then step to the side on the other foot, and conclude the figure by closing the first foot beside the second (hence the name "closed" of the step). Each step takes up a full beat of the music. Cross-body lead Cross-body lead is a common and useful move in Latin dances such as salsa, mambo, rumba and cha-cha-cha. Basically, the leader, on counts 2 and 3 of their basic step (assuming dancing on 1), does a quarter-left turn (90° counter-clockwise) while still holding on to the follower. On counts 4 and 5, the follower is led forward across the leader, i.e., firmly led with the leader's right hand on their back, so that the follower travels across to turn and face the opposite direction they were originally facing. At the same time, the leader does another quarter-left turn as necessary in order to follow the follower and face them. At the end of the move, the dancers have their positions exchanged. The cross-body lead can be done with single-hand or double hand hold, with or without a follower's underarm turn, or leading the follower to do a free spin. Dos-à-dos / dosado Dosado is a circular movement where two people, who are initially facing each other, walk around each other without or almost without turning, i.e., facing in the same direction (same wall) all the time. Double reverse spin The double reverse spin is a full left (counter-clockwise) turn in one measure of music. It is danced in waltz, quickstep and tango. Enchufla This is a dance movement common in salsa, where the two dance partners facing each other change positions. The dance partners keep contact with one or two hands while stepping to rotate concentrically over 180 degrees around the same point in opposite directions. Feather step The feather step is a basic figure in International Style foxtrot, in which the leader makes three or four steps forward, with the third one (right foot) done outside the follower. Floss Free spin In lead and follow dance, a dance turn performed without partner contact. Gancho "Gancho" means "hook" in Spanish and describes certain "hooking actions" in some dances of Latin American heritage, in Argentine tango (leg action) and salsa (arm action and foot action) in particular. Grapevine The grapevine or vine starts with a side step, then the working leg goes behind, then stepping to the side, then join. Head roll Heel pull A variant of the heel turn, in which the feet are kept apart. Heel turn A ballroom dance move, which is the turn on the heel of the support foot while the other foot is held close and parallel to the support one. At the end of the turn the weight is transferred from one foot to the other. Impetus The impetus is a kind of leader's heel turn used in Standard dances. In case of the open impetus, it brings the couple from a closed position into promenade position. Inside partner step A step taken forward into the space occupied by the partner, while the partner steps backwards. During this step feet tracks of both partners overlap. See also outside partner step. Inside turn The term is applied to an individual turn of a partner in the couple. Basically, it denotes a turn where the arm of the partner doing the turn begins by moving towards the "inside" of the couple (the line running from the center of one partner to the center of the other). The meaning is intuitively clear, but it may be performed in numerous ways and in different handholds, so that even accomplished dancers are confused. In dances such as swing and salsa, inside and outside turns most commonly refer to underarm turns done by the follower. Since in these dances the follower's right arm is normally used to lead a turn (most commonly by the leader's left arm, but sometimes by the leader's right arm when a cross-hand or "handshake" position is used), an inside turn is normally a left (counter-clockwise) turn, while an outside turn is a right (clockwise) turn. However, if the follower's left arm is used to initiate the turn, the intended direction of turning may be opposite. (Alternatively, the non-ambiguous terms "left turn" and "right turn" may be used.) See Direction of movement for more detail. Kick Moving the knee upwards and then quickly kicking downwards with the foot. The ankle is stretched, that is, the toes are pointing down. L–Z Lock step A lock step is an alternative variation of a chassé action which occurs when the moving foot swings to a stop across the track of the standing foot rather than closing next to it. In the Latin dances the combination of the crossed position and the turnout of the feet means that the rear toe will be pointed at the heel of the other foot, while in the Standard dances the lack of turnout means the feet will be parallel. In Standard the basic locking action is usually preceded and followed by a left side lead. The Latin lock step is often featured when cha-cha is danced in open position with a one-hand hold. Moonwalk The moonwalk is a dance technique that presents the illusion of the dancer being pulled backwards while attempting to walk forward. Natural turn Natural turns and some other figures are those in which the dance couple rotates to the right (clockwise). Open turn A ballroom dance figure in which during the last step the moving foot passes the support foot, rather than closes to it. Outside partner step A step taken with the partner beside the moving foot (e.g., to the left of the left moving foot). During this step feet tracks of both partners do not overlap. See also inside partner step. Outside turn Cf. Inside turn. The term is applied to an individual turn of a partner in the couple. Basically, it denotes the lead/follow connection directed "outside" of the center of the spinning individual. Inside and outside terminology can not be determined by relativity to partnership as such position alternates every 180 degrees of rotation. Connection points and application of active side are consistent only with regard to the axis of rotation and direction of spin. See Direction of movement for more detail. Pirouette A pirouette usually means turning or spinning on one foot while touching the standing leg with the opposite leg in a bent position. Reverse turn Reverse turns and some other figures are those in which the dance couple rotates to the left (counter-clockwise). Rondé See Ballet glossary#Rond de jambe. A toe of the straight leg draws a semicircle on the floor. In ballroom dances the direction is usually from the front to back. Shorty George A forward walk with twisted knees originally performed by George Snowden. Spin turn The natural spin turn is a common right-turning move in international standard waltz and quickstep. It can be used, for example, to navigate a corner of the ballroom. Sprinkler The sprinkler is a dance move that simulates the motion of a garden irrigation sprinkler. Suzie Q Suzie Q or Suzy Q is a step where the feet perform alternating cross steps and side steps with swivel action. Telemark Thunder clap The thunder clap is a form of dance that incorporates clapping in the air with a sliding motion. To perform this dance one must raise one hand and then with the second hand meet the first one half way making a clapping sound; that hand must then fully extend. This motion is repeated to the beat of the music. Time step In tap dancing, the time step is a recognizable rhythmic tap combination. The term comes from the time of great tap dancers that used their distinctive time step to tell the band the desired tempo. Common tap time steps are classified as single, double and triple. The basic rhythm and tempo remain the same but the number of sounds that happen on the second and sixth count of an eight-count phrase denotes single (often a single step) double (usually a flap or slap-tap) or triple (commonly shuffle-step). While these are the universal time steps, dancers often choose to create their own time steps, following the pattern two bars repeated three times with a two bar break. Time steps is a figure in International Style cha-cha-cha. In various rhythmic ballroom/social dances, time step sometimes refers to steps in place that mark the characteristic rhythm of the dance, "2-3-cha-cha-cha" for Cha-cha-cha, "1,2,3,4" for pasodoble, "1,2,3,...5,6,7,..." for "salsa on one", etc. Walk The walk is probably the most basic dance move. It exists in almost every dance. Walks approximately correspond normal walking steps, taking into the account the basic technique of the dance in question. (For example, in Latin-dance walks the toe hits the floor first, rather than the heel.) In dance descriptions the term walk is usually applied when two or more steps are taken in the same direction. A single step, e.g., forward, is called just thus: "step forward". Walks can be done in various dance positions: in closed position, promenade position, shadow position, sweetheart position, etc. Curved walks are done along a curve, rather than along a straight line. Whisk The various kinds of whisk are dance moves in International Standard and American Smooth dances. They are characterised by the partners crossing their outside legs behind their inside legs, arriving in promenade position. Wing The wing is a move in waltz and other Standard dances. Both partners take a step forward, and then the lady walks in a half-circle in front of the man from his right to his left side. See also Glossary of ballet terms Glossary of partner dance terms References Dance moves Wikipedia glossaries using subheadings
Fabrizio Lasagna (born 26 June 1988) is an Italian professional footballer who plays as a forward. On 14 July 2011, he joined Avellino in a definitive deal. Caps on Italian Series Serie C1: 50 caps, 5 goal Serie C2: 24 caps, 3 goal Total: 74 caps, 8 goal References External links Living people 1988 births US Vibonese Calcio players Men's association football forwards Italian men's footballers Paganese Calcio 1926 players US Avellino 1912 players Footballers from Palermo
```shell #!/usr/bin/env bash # set -x CUR_DIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd) # shellcheck source=../shell_config.sh . "$CUR_DIR"/../shell_config.sh echo -ne '0\t1\t2\t3\t4\t5\t6\t7\t8\t9\t10\ta' | $CLICKHOUSE_LOCAL --structure 'c0 UInt8, c1 UInt8, c2 UInt8, c3 UInt8, c4 UInt8, c5 UInt8, c6 UInt8, c7 UInt8, c8 UInt8, c9 UInt8, c10 UInt8, c11 UInt8' --input-format TSV --query 'SELECT * FROM table' --input_format_tsv_detect_header=0 2>&1 | grep -F 'Column 11' ```
Fiorella Aíta Junek (born 13 July 1977) is a Peruvian volleyball player. She competed in the women's tournament at the 2000 Summer Olympics. References External links 1977 births Living people Peruvian women's volleyball players Olympic volleyball players for Peru Volleyball players at the 2000 Summer Olympics Sportspeople from Lima 20th-century Peruvian women 21st-century Peruvian women
```java /* * one or more contributor license agreements. See the NOTICE file distributed * with this work for additional information regarding copyright ownership. */ package io.camunda.zeebe.engine.util; import static java.nio.file.FileVisitResult.CONTINUE; import static java.util.stream.Collectors.joining; import static org.junit.platform.commons.util.ReflectionUtils.makeAccessible; import io.camunda.zeebe.db.TransactionContext; import io.camunda.zeebe.db.ZeebeDb; import io.camunda.zeebe.engine.EngineConfiguration; import io.camunda.zeebe.engine.state.DefaultZeebeDbFactory; import io.camunda.zeebe.engine.state.ProcessingDbState; import io.camunda.zeebe.engine.state.message.TransientPendingSubscriptionState; import io.camunda.zeebe.engine.state.mutable.MutableProcessingState; import io.camunda.zeebe.protocol.Protocol; import io.camunda.zeebe.protocol.ZbColumnFamilies; import io.camunda.zeebe.stream.impl.state.DbKeyGenerator; import java.io.IOException; import java.nio.file.FileVisitResult; import java.nio.file.Files; import java.nio.file.NoSuchFileException; import java.nio.file.Path; import java.nio.file.SimpleFileVisitor; import java.nio.file.attribute.BasicFileAttributes; import java.time.InstantSource; import java.util.SortedMap; import java.util.TreeMap; import org.junit.jupiter.api.extension.BeforeEachCallback; import org.junit.jupiter.api.extension.ExtensionContext; import org.junit.jupiter.api.extension.ExtensionContext.Namespace; import org.junit.jupiter.api.extension.ExtensionContext.Store; import org.junit.jupiter.api.extension.ExtensionContext.Store.CloseableResource; import org.junit.platform.commons.util.ExceptionUtils; import org.junit.platform.commons.util.ReflectionUtils; import org.junit.platform.commons.util.ReflectionUtils.HierarchyTraversalMode; /** * Extension that creates a temporary folder, and sets up a Zeebe database in that temporary folder. * The extension injects instances of * * <ul> * <li>{@code ZeebeDb} (exact type match) * <li>{@code TransactionContext} (exact type match) * <li>{@code MutableProcessingState} (exact type match or supertypes) * </ul> * * on fields with the corresponding type. * * <p>Usage: * * <pre>{@code * @ExtendWith(ProcessingStateExtension) * public class Test { * private ZeebeDb db; //will be injected * private TransactionContext txContext; //will be injected * private MutableProcessingState state //will be injected * * ... * } * }</pre> * * <p>Not Supported: * * <pre>{@code * private ZeebeDb db1; // will be injected * private ZeebeDb db2; // will be injected, but will be the same instance as db1 * }</pre> */ public class ProcessingStateExtension implements BeforeEachCallback { private static final String FIELD_STATE = "state"; @Override public void beforeEach(final ExtensionContext context) { context .getRequiredTestInstances() .getAllInstances() .forEach(instance -> injectFields(context, instance, instance.getClass())); } public ProcessingStateExtensionState lookupOrCreate(final ExtensionContext extensionContext) { final var store = getStore(extensionContext); return (ProcessingStateExtensionState) store.getOrComputeIfAbsent(FIELD_STATE, (key) -> new ProcessingStateExtensionState()); } private void injectFields( final ExtensionContext context, final Object testInstance, final Class<?> testClass) { ReflectionUtils.findFields( testClass, field -> ReflectionUtils.isNotStatic(field) && field.getType() == ZeebeDb.class, HierarchyTraversalMode.TOP_DOWN) .forEach( field -> { try { makeAccessible(field).set(testInstance, lookupOrCreate(context).getZeebeDb()); } catch (final Throwable t) { ExceptionUtils.throwAsUncheckedException(t); } }); ReflectionUtils.findFields( testClass, field -> ReflectionUtils.isNotStatic(field) && field.getType() == TransactionContext.class, HierarchyTraversalMode.TOP_DOWN) .forEach( field -> { try { makeAccessible(field) .set(testInstance, lookupOrCreate(context).getTransactionContext()); } catch (final Throwable t) { ExceptionUtils.throwAsUncheckedException(t); } }); ReflectionUtils.findFields( testClass, field -> ReflectionUtils.isNotStatic(field) && field.getType().isAssignableFrom(MutableProcessingState.class), HierarchyTraversalMode.TOP_DOWN) .forEach( field -> { try { makeAccessible(field) .set(testInstance, lookupOrCreate(context).getProcessingState()); } catch (final Throwable t) { ExceptionUtils.throwAsUncheckedException(t); } }); } private Store getStore(final ExtensionContext context) { return context.getStore(Namespace.create(getClass(), context.getUniqueId())); } private static final class ProcessingStateExtensionState implements CloseableResource { private Path tempFolder; private ZeebeDb<ZbColumnFamilies> zeebeDb; private TransactionContext transactionContext; private MutableProcessingState processingState; private ProcessingStateExtensionState() { final var factory = DefaultZeebeDbFactory.defaultFactory(); try { tempFolder = Files.createTempDirectory(null); zeebeDb = factory.createDb(tempFolder.toFile()); transactionContext = zeebeDb.createContext(); final var keyGenerator = new DbKeyGenerator(Protocol.DEPLOYMENT_PARTITION, zeebeDb, transactionContext); processingState = new ProcessingDbState( Protocol.DEPLOYMENT_PARTITION, zeebeDb, transactionContext, keyGenerator, new TransientPendingSubscriptionState(), new TransientPendingSubscriptionState(), new EngineConfiguration(), InstantSource.system()); } catch (final Exception e) { ExceptionUtils.throwAsUncheckedException(e); } } @Override public void close() throws Throwable { transactionContext.getCurrentTransaction().rollback(); zeebeDb.close(); final SortedMap<Path, IOException> failures = clearFolder(); if (!failures.isEmpty()) { throwException(failures); } } private void throwException(final SortedMap<Path, IOException> failures) throws IOException { final String joinedPaths = failures.keySet().stream().map(Path::toString).collect(joining(", ")); final IOException exception = new IOException( "Failed to clear temp directory " + tempFolder.toAbsolutePath() + ". The following paths could not be deleted: " + joinedPaths); failures.values().forEach(exception::addSuppressed); throw exception; } private SortedMap<Path, IOException> clearFolder() throws IOException { final SortedMap<Path, IOException> failures = new TreeMap<>(); Files.walkFileTree( tempFolder, new SimpleFileVisitor<>() { @Override public FileVisitResult visitFile( final Path file, final BasicFileAttributes attributes) { return delete(file); } @Override public FileVisitResult postVisitDirectory(final Path dir, final IOException exc) { return delete(dir); } private FileVisitResult delete(final Path path) { try { Files.delete(path); } catch (final NoSuchFileException ignore) { // ignore } catch (final IOException exception) { try { path.toFile().deleteOnExit(); } catch (final UnsupportedOperationException ignore) { // ignore } failures.put(path, exception); } return CONTINUE; } }); return failures; } private ZeebeDb<ZbColumnFamilies> getZeebeDb() { return zeebeDb; } private MutableProcessingState getProcessingState() { return processingState; } private TransactionContext getTransactionContext() { return transactionContext; } } } ```
The Poisson-Blanc Regional Park (in French: Parc régional du Poisson-Blanc) is a regional park located at the Poisson-Blanc Lake (or Poisson-Blanc Reservoir) in the municipality of Notre-Dame-du-Laus, in the Antoine-Labelle Regional County Municipality, in administrative region of Laurentides, in Quebec, in Canada. This park is administered by the "Corporation du Parc du Poisson-Blanc" (trans-en|Poisson-Blanc Parks Development Corporation) (CPPB) which is a non-profit organization and whose head office is located at 37 ch. de la Truite, Notre-Dame-du-Laus, Quebec, J0X 2M0. The CPPB was registered on March 7, 2005 in the Quebec enterprise register. This organization's mission is to see to the development and integrated management of the recreational tourism resources of Notre-Dame-du-Laus. This organization is mandated by the Antoine-Labelle Regional County Municipality, as well as the municipality of Notre-Dame-du-Laus for the operations of the park. The Poisson-Blanc Regional Park has been created in 2008. The Bastion reception pavilion is located at on a peninsula west of the village of Notre-Dame-de-Laus. It is also possible to access the Poisson Blanc reservoir from the south (Bowman/Denholm); if necessary, excursionists must rent boats at the Air-Eau-Bois outdoor base. Geography The Poisson-Blanc regional park is located on the east shore of Poisson-Blanc Lake, near Notre-Dame-du-Laus village. History In 2002, the creation of a regional park in Notre-Dame-du-Laus was already under consideration. In 2005, the Corporation du Parc du Poisson Blanc was formed. The organizers then drafted a plan to develop the islands of the Poisson-Blanc Lake. In 2006-2007, the organization hired three technicians to undertake and coordinate the cleaning of the tank. Particularly in collaboration with the Air-Eau-Bois outdoor base, numerous chores made it possible to remove approximately two tons of waste left on the islands by unsupervised human activities. Among the initiatives deployed for cleaning up the islands, latrines have been set up on several islands. In 2008, the Poisson Blanc Regional Park was officially created. Reservation of campsites on the islands will begin in 2009. In 2010, the park adds canoe and kayak rental services. Between 2008 and 2012, park workers set up a system of supervision and monitoring of activities on the islands of the reservoir. In addition, the park has developed approximately 10 km of hiking trails in Devil's Mountain. At the start of the 2012 season, the Le Bastion reception pavilion was inaugurated. Activities The park is open year round. Several hiking trails in the Poisson Blanc Regional Park are accessible by car from the parking lot in the Rapide-du-Fort sector and the Lac Cuillèrier sector. These trails are located on the Fort mountain. The park offers hiking trails in the island sector of Poisson-Blanc Lake; these trails are accessible only by using a water craft. On the islands, at the end of each hiking route, hikers will have a striking glance of the Poisson Blanc reservoir. In winter, users can go snowshoeing. Many park users canoe/kayak/sup-camping on the Poisson-Blanc Lake. Exercise practitioners can then stop for picnics, swimming or relaxing in the sun on the wild beaches. To accommodate users, the park offers a canoe, kayak and paddleboard rental service at Bastien, the park's reception pavilion in Notre-Dame-du-Laus. Accommodation This regional park is offering 17 picnic stops on the islands of the reservoir. It offers also camping sites on the islands and in micro-shelters in the forest. The Grand-Pic (accommodating 4 peoples) is a micro-refuge design for rooted in nature and is located at the end of the Pointe de la Truite. This strategic site is bordered on all sides by the Poisson-Blanc Lake. Le Pic-Mineur is a micro-refuge located just a few meters from the Poisson Blanc Reservoir. Toponym This toponym is linked to the name of Poisson-Blanc Lake. This name of the lake and the river derives from the fact that white fish are caught there. The toponym "Poisson-Blanc regional park" was formalized on May 13, 2016 at the Place name bank of the Commission de toponymie du Québec. Notes and references External links Parc régional du Poisson Blanc (Poisson-Blanc Regional Park) Protected areas of Lanaudière Matawinie Regional County Municipality Regional Parks of Quebec Nature reserves in Quebec
Schilling & Graebner (or Gräbner) was an architecture firm based in Dresden, Germany, founded by the architects Rudolf Schilling (1859–1933) and Julius Graebner (1858–1917) in 1889. The firm was under their direction from 1889 until Graebner's death, but continued to exist until 1947, most notably under Graebner's son Erwin (1895–1945). The firm, which initially devoted itself primarily to historicism and later to Art Nouveau and early modernism, worked on mainly buildings in Saxony, including several noteworthy churches, Dresden villas, administrative buildings and entire residential districts. One of the firms' most important works is the Christuskirche in Dresden (1903–1905), which arguably marks the transition of sacral architecture in Germany from historicism to modernity. Early life and formation of the partnership Both Schilling and Graebner had met each other when they were just over 20 years old around 1881 while studying architecture at the Polytechnikum Dresden. Even when they initially went their separate ways after completing their training, they did not lose touch, especially since they both worked in Berlin in two different offices in the mid-1880s. The two architects, who were roughly the same age, complemented each other very well. Together they were a formidable and very versatile team, as evidenced by the fact that they not only designed very complex buildings, but they also showed great stylistic differences amongst their entire oeuvre. Schilling, as the son of the well-known sculptor Johannes Schilling, provided the necessary start-up capital and contacts to numerous potential clients. Graebner's strength, on the other hand, was more artistic design. Schilling and Graebner hired several trained architects in their firm over the years, including Oswald Bieber, Heino Otto and Johannes Rascher. During the late nineteenth century, their biggest local competitors were probably William Lossow and Fritz Schumacher. At that time, Schilling and Graebner were the leading architects of the fifth largest city in the German Empire. They were generally considered within the first rank of German architects and were particularly regarded as experts in contemporary Protestant church architecture. They were also inspired in their work by suggestions from Franz Wilhelm Dibelius and Cornelius Gurlitt. Stylistic evolution At first, Schilling & Graebner preferred late historicism in their works in Dresden. Their first building commission, the Pieschen town hall, completed in 1891, shows clear features of the Neo-Renaissance, as well as the Villa Muttersegen built in 1891 in Blasewitz or the Lutherkirche in Radebeul. In the years before the turn of the century, Schilling and Graebner also designed neo-baroque buildings, such the commercial building called the Imperial Palace for Hermann Ilgen at Pirnaischer Platz that burned in 1945 during the bombing of Dresden and was later demolished. In 1895 they also designed the neo-baroque interior of the Schellenberger City Church of St. Peter, which was destroyed after a fire. and around 1900 that of the Dresden Kreuzkirche. The latter also showed a significant influence from Jugendstil. For a long time, Schilling and Graebner represented the views in line with the development of Heimatschutz Architecture as it emerged around the turn of the century. With their practice flourishing, in 1899 Schilling and Graebner bought the large winery of Altfriedstein in the present Radebeul district of Dresden and developed the site by laying roads and parcelling the abandoned wine-growing areas into a "Villa Colony Altfriedstein." To do this, they tore down the west wing of the mansion and all the outbuildings of the winery and redesigned the west gable of the remaining east wing. Among other things, they built a pedestrian passage through the corner of the building on the ground floor. From 1902 until the First World War they built numerous villas and country houses there, many of them in the Heimatschutzstil, also called the "Reform Architecture Style." After about 1902, Schilling and Graebner tried to overcome historicism and turned more to a kind of proto-modernism, which was particularly difficult in church building due to the Eisenach regulations that applied there. The first signs of modernity are the residential buildings built in the early twentieth century for the Dresdner Spar- und Bauverein with their austere facades and high functionality. The Christuskirche in Strehlen, built in 1903–05, went far beyond Art Nouveau and points in this direction, which is also very clearly expressed in the Zionskirche in the Dresden Südvorstadt built in 1912–14, but partially destroyed in 1945. This pioneering work also meant that the two architects were invited to join several professional associations. Graebner was member of the directorate of the Dürerbund. As members of the Deutscher Werkbund Schilling and Graebner designed many of their later villas, public and sacral buildings according to the principles of modernity as propagated by this association of artists and industry. The former Zionskirche, built from 1908 to 1912 and destroyed in 1945, was an extraordinary example of this architectural style. However, despite this general line of evolution, it is worth noting Schilling and Graebner also liked to experiment with mixtures of styles. Work after 1917 After Julius Graebner died in 1917, the firm was continued by his son Erwin Graebner, who returned from the Western Front in October 1918, and replaced his father in partnership with Rudolf Schilling. During this period, further plans for larger buildings such as the Kriegersiedlung in Trachau and the development on the west side of Aachener Strasse in Dresden were implemented. Schilling died in 1933 and Erwin Graebner ran the office alone from then on. During this time he developed, among other things, the plans for several factory buildings of the Leipziger Kammgarnspinnerei, which were blown up in 2007 and captured on video. In 1947, two years after Erwin Graebner's death, the firm was finally dissolved. Selected works Villas Goetheallee 24 (Pernwaldhaus/Villa Muttersegen), Blasewitz, begun 1891, Neo-Renaissance Goetheallee 26 (:de:Villa Fliederhof), built in 1891, burned down and demolished in 1979 Kaitzer Str. 82, Dresden-Plauen, built in 1891, renovated in 1999 Barteldesplatz 2, Blasewitz, 1893, Neo-Renaissance style, today the seat of the Bürgerstiftung Dresden Goetheallee 43, Blasewitz, 1894, eclectic Extension to the Villa Zillerstraße 5, Niederlößnitz, 1895 :de:Villa Friedrichsruh, Hermsdorfer Straße 16, Löbtau, 1898 :de:Villa Rautendelein for Gerhart Hauptmann, Hochuferstraße 12 (today Käthe-Kollwitz-Ufer 84), Blasewitz, 1899–1900, destroyed in 1945 Franz-Liszt-Strasse 19, Strehlen, 1899 Hähnelstraße 13, Johannstadt, four-story country house, destroyed Degelestraße 3 (Villa Wolff), Weißer Hirsch, 1901, Neo-Baroque Residential colony Altfriedstein in the Niederlößnitz district of Radebeul, from 1902 Conversion of the mansion Altfriedstein, 1902 Villa at Prof.-Wilhelm-Ring 20, 1902 Landhaus Ludwig-Richter-Allee 27, 1902—03 Country house Prof.-Wilhelm-Ring 16 (Radebeul), 1903 Hermann Ebert tenement house, Moritzburger Strasse 45, 1903 Villa Elisabeth's peace, Prof.-Wilhelm-Ring 10, 1903 House at Lindenaustrasse 7 (Radebeul), 1903—04 House Schilling, Auenstraße 51, Apolda, Thuringia, 1904—06 Detached house at Ludwig-Richter-Allee 30, 1905 Detached house at Ludwig-Richter-Allee 31, 1905—06 Detached house at Ludwig-Richter-Allee 32, 1905—06 Detached house at Ludwig-Richter-Allee 33, 1905—06 Paul Nieschke House, Ludwig-Richter-Allee 28, 1906 Landhaus Lutzmann House, Lindenaustrasse 3, 1906 Landhaus Prof.-Wilhelm-Ring 18, 1906 Villa Alfred Sparbert, Prof.-Wilhelm-Ring 19, 1907 Landhaus Altfriedstein 7, 1910 Meyerburg, Mohrenstrasse 5, 1911—12 Landhaus Lindenaustrasse 1, 1916—17 Villa Würzburger, Johannstadt, 1910 Churches Lutherkirche (Radebeul), Neo-Renaissance, 1891 (with neighboring vicarage and the associated cemetery chapel on the Friedhof Radebeul-Ost) Church in :de:Hohenfichte, 1893–96 Interior of the Church of St. Peter in Schellenberg, Neo-Baroque, 1895 Resurrection Church in Stenn, 1895–96 Competition design for the new church in Leuben, 1898, 2nd prize, not executed New interior of the burnt out Kreuzkirche in Dresden, 1897–1900, destroyed during the Second World War except for small remains Conversion of the evangelical church in Cannewitz, 1900 New tower of the evangelical church in Bergen (Vogtland), 1900 Protective porch for the Golden Gate at the Freiberg Cathedral, 1902 Christ Church (so-called “Green Church”) in Teplice, (now Czech Republic), 1899–1905, Art Nouveau, demolished 1973 Lutherkirche in Dux, 1899–1901 Churches in Hohenelbe and Klostergrab, 1900–03 Church of the German Evangelical Congregation in Mittel Langenau, 1902, elevated to a parish church in 1916, demolished in 1979 St. Trinity Church in Wiesa (Ore Mountains), 1902–1904 Christuskirche in Dresden-Strehlen, 1903–05 Cemetery chapel in Rochlitz, 1905 Lutherkirche in Zwickau, Art Nouveau, built in 1906 as a garrison church Reconstruction of the cruciform church in Hirschberg in the Giant Mountains, 1909 Conversion of the Jakobikirche in Chemnitz, redesign of the west facade, Art Nouveau, 1911 Zionskirche, Südvorstadt, Dresden, 1912–14 Peace Church in Aue-Zelle, 1912–14 Design for a Protestant parish church in Schinkel near Osnabrück, published in 1915 Design for a Protestant parish church in :de:Reumtengrün near Auerbach/Vogtl., published in 1915 Villa Würzburger, Johannstadt, 1910 Houses in Dresden Leipziger Strasse 32—34, :de:Leipziger Vorstadt, residential buildings for the Dresdner Spar- und Bauverein, 1901, sparsely decorated and functionalist Coschützer Strasse 54—56, Plauen, residential buildings for the Dresden Spar- und Bauverein, 1902, sparsely decorated and functionalist Warrior settlement Dresden-Trachau, 1921–26, Trachau housing estate, together with Hans Richter, Hans Waloschek and others, 1928–39, especially rows of houses on Aachener Straße "Rudolf-Schilling-Haus" on Holbeinstrasse and Tittmannstrasse, today the Johannstadt housing association Reick settlement, together with :de:Rudolf Bitzan and others Other buildings and projects Expansion of the facilities of the Sonnenstein Sanitary Home in Pirna (from 1890) Old :de:Friedhofskapelle Friedhof Radebeul-Ost, 1890 Pieschen Town Hall, 1890–91 Commercial building Kaiserpalast for Hermann Ilgen on Pirnaischer Platz in Dresden, 1896, neo-baroque style, burned 1945, demolished 1951 Löbtau Town Hall, 1896–98, destroyed Draft of a restoration building in the form of a Japanese Rococo pavilion for the 1897 German Art Exhibition in Dresden Hotel Ratskeller in Schwarzenberg (reconstruction of the burnt down town hall, 1906) Draft for the portal to the arts and crafts department and large hall for the German Art Exhibition in 1899 Wine salon Stadt Gotha in Dresden-Altstadt, Schloßstraße 11, 1900, destroyed Sächsische Handelsbank, Ringstraße 10/12, Dresden-Altstadt, 1900 Coffee shop Max Thürmer in the Viktoriahaus, Waisenhausstraße, Dresden-Altstadt, 1901, destroyed Wettin Fountain in Waldheim (Saxony), 1902–03 AOK administration building at Sternplatz in Dresden, :de:Wilsdruffer Vorstadt, 1912–13 Consecration hall, mortuary, gardener's house and gate at the St. Pauli Cemetery in Dresden, 1909 Exhibition stand for the Rother'sche Kunstziegeleien GmbH / Ceramic art workshops Richard Mutz & Rother GmbH from Liegnitz (Lower Silesia) at the II. German Clay, Cement and Lime Industry Exhibition in Berlin-Baumschulenweg Spa center Bad Gottleuba, 1909–13, 34 Art Nouveau buildings Some buildings of the :de:Lahmann Sanatorium in Dresden-Weißer Hirsch, 1912 Dyeing and sorting building of Kammgarnspinnerei AG in Leipzig, Dr.-Kurt-Fischer-Straße 31, 1934–36, demolished in 2007 Further reading Ricarda Kube, "Schilling und Graebner (1889–1917) – Das Werk einer Dresdner Architektenfirma." Dissertation an der Technischen Universität Dresden, 2 volumes, 1988. Landkirchen. Entworfen und ausgeführt von den Architekten Schilling & Graebner. Mit einem Geleitwort von Dr. Paul Schumann. Leipzig, Gilbertsche Verlagsbuchhandlung, 1903. Guy Eglinton, Peyton Boswell: International studio, Vol. 13. New York Offices of the International Studio, 1901, pp. 283, 284. Ralph Adams Cram: Christian art: an illustrated monthly magazine devoted to current church building, American and foreign, and the allied ecclesiological arts, with expert discussions of all topics relating to Christian archaeology, Vol. 4. R.S. Badger, 1908, pp 14–18. Schilling und Graebner, Architekten BDA, Dresden. Eine Auswahl. Bauten von 1918–1928. Maximilian Maul, Berlin 1928. Volker Helas, ed., Stadt Radebeul. Beucha: Sax-Verlag/Landesamt für Denkmalpflege Sachsen, Große Kreisstadt Radebeul, 2007, . Tobias Michael Wolf, Die Villenkolonie Altfriedstein in Niederlößnitz / Radebeul. Werk der Dresdner Architektenfirma Schilling & Graebner. (Magisterarbeit, Technische Universität Dresden, 2005) VDM Verlag Dr. Müller, Saarbrücken 2008. (Book-on-Demand) References External links Schilling & Graebner at Europeana Protestantischer Kirchenbau von Schilling & Graebner (PDF; 925 kB) Architecture firms of Germany Companies based in Dresden Art Nouveau architects Modernist architects Design companies established in 1889 Design companies disestablished in 1947 1889 establishments in Germany 1947 disestablishments in Germany
Princess Marie Gasparine of Saxe-Altenburg (Marie Gasparine Amalie Antoinette Karoline Elisabeth Luise; 28 June 1845 – 5 July 1930) was a daughter of Prince Eduard of Saxe-Altenburg and his wife Princess Louise Caroline Reuss of Greiz. She was the consort of Charles Gonthier, Prince of Schwarzburg-Sondershausen. Marriage Marie was considered as a potential spouse for Albert Edward, Prince of Wales, the eldest son and heir of Queen Victoria. A London newspaper speculated (supposedly from "authentic sources") that the prince's choices were limited to seven women, who were all of sufficient royal blood, followers of a Protestant religion, and his age or younger. Some of the other candidates included Marie of the Netherlands, Elisabeth of Wied, Anna of Hesse-Darmstadt, Alexandrine of Prussia, Alexandra of Denmark, Wilhelmine of Württemberg, Catherine of Oldenburg and Augusta of Schleswig-Holstein. Marie was eliminated from this list however, as she was considered "shockingly dressed and always with her most disagreeable mother," and the Prince of Wales ultimately married Alexandra of Denmark in 1863. On 12 June 1869, Marie married Charles Gonthier, Hereditary Prince of Schwarzburg-Sondershausen in Altenburg. Charles succeeded his father on 17 July 1880, and Marie became the Princess of Schwarzburg-Sondershausen. Their failure to have children meant the end of the House of Schwarzburg-Sondershausen. Charles' cousin Günther Victor succeeded him in 1909. Marie Gasparine died on 5 July 1930 in Sondershausen, Weimar Republic. Ancestry References External links An older picture of Marie Gasparine 1845 births 1930 deaths Nobility from Munich House of Saxe-Altenburg Princesses of Saxe-Altenburg House of Schwarzburg Princesses of Schwarzburg
Turnin' Back the Pages is a compilation album released by Stephen Stills from his years with Columbia Records (1975-1978) and the Super Session album (1968). It was released in 2003. Track listing Stephen Stills compilation albums 2003 compilation albums
Ziyu "Sally" Zhang (born 10 December 1990) is an Australian table tennis player. She competed at the 2016 Summer Olympics as part of the Australian team in the women's team event. References 1990 births Living people Olympic table tennis players for Australia Table tennis players at the 2016 Summer Olympics Commonwealth Games medallists in table tennis Commonwealth Games bronze medallists for Australia Naturalised table tennis players Table tennis players from Shijiazhuang Table tennis players at the 2014 Commonwealth Games Medallists at the 2014 Commonwealth Games
Manuel E. Amador Terreros is a corregimiento in Las Palmas District, Veraguas Province, Panama. References Corregimientos of Veraguas Province
```java /** * <p> * <p> * path_to_url * <p> * Unless required by applicable law or agreed to in writing, software * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */ package com.justwayward.reader.base; /** * @author yuyh. * @date 16/8/6. */ public interface BaseContract { interface BasePresenter<T> { void attachView(T view); void detachView(); } interface BaseView { void showError(); void complete(); } } ```
John Cowell (1554 – 11 October 1611) was an English jurist. Life Born at Ernesborough (now Irishborough), in the parish of Swimbridge in North Devon. He was a chorister in the Choir of King's College, Cambridge and was then educated at Eton College before returning as a scholar at King's College, Cambridge, where he was elected a fellow. In 1594 he became Regius Professor of Civil Law at Cambridge, and in 1598 master of Trinity Hall, Cambridge. He died at Oxford on 11 October 1611, soon after being released from prison, and was buried in Trinity Hall Chapel, Cambridge. Works In 1607, he compiled a law dictionary, The Interpreter, in which he exalted the king's prerogative; he was prosecuted before the House of Commons by Sir Edward Coke, who had a hostile history with Cowell. He was saved from imprisonment only by the interposition of James I. His book was burnt by order of the House of Commons. The suppression order read in part: When Men goe out of their Element, and meddle with Things above their Capacitie, themselves shall not onely goe astray and stumble in Darknesse, but will mislead also divers others with themselves into many Mistakings and Errours.. the Proofe whereof wee have lately had by a Booke written by Docteur Cowell.. by medling in Matters above his reach, he hath fallen in many Things to mistake and deceive himselfe.. in some Poynts very derogatory to the supreme Power of this Crowne; In other Cases mistaking the true State of the Parliament of this Kingdome... Many copies survived the burning and have been reprinted. A copy of the 1607 printing can be found at the Lilly Library in Bloomington, Indiana. "The Interpreter" was one of the first law dictionaries. Cowell also wrote a work entitled Institutiones Juris Anglicani. The book has been described as an English version in the Justinian style. It also hints a correlation of Scottish and English law. Notes References External links 1554 births 1611 deaths Writers from Barnstaple People educated at Eton College Alumni of King's College, Cambridge English legal scholars Masters of Trinity Hall, Cambridge 16th-century English educators 17th-century English writers Vice-Chancellors of the University of Cambridge Regius Professors of Civil Law (University of Cambridge) Choristers of the Choir of King's College, Cambridge
Beitanzhuang Township () is a township of Lingshou County, Shijiazhuang, Hebei province, China, located in the eastern foothills of the Taihang Mountains northwest of the county seat. , it had 12 villages under its administration. See also List of township-level divisions of Hebei References Township-level divisions of Hebei
```swift // // UtilityTests.swift // GeometryScriptTests // // Created by Nick Lockwood on 07/11/2018. // import XCTest @testable import Euclid class UtilityTests: XCTestCase { func testLinuxTestSuiteIncludesAllTests() { #if os(macOS) let thisClass = type(of: self) let linuxCount = thisClass.__allTests.count let darwinCount = thisClass.defaultTestSuite.testCaseCount XCTAssertEqual(linuxCount, darwinCount, "run swift test --generate-linuxmain") #endif } // MARK: convexness func testConvexnessResultNotAffectedByTranslation() { let vectors = [ Vector(-0.10606601717798211, 0, -0.10606601717798216), Vector(-0.0574025148547635, 0, -0.138581929876693), Vector(-0.15648794521398243, 0, -0.1188726123511085), Vector(-0.16970931752558446, 0, -0.09908543035921899), Vector(-0.16346853203274558, 0, -0.06771088298918408), ] XCTAssertTrue(pointsAreConvex(vectors)) let normal = Vector(0, 1, 0) let offset = Vector(0, 0, 3) let vertices = vectors.map { Vertex($0, normal).translated(by: offset) } XCTAssertTrue(verticesAreConvex(vertices)) } func testColinearPointsDontPreventConvexness() { let vectors = [ Vector(0, 1), Vector(0, 0), Vector(0, -1), Vector(1, -1), ] XCTAssertTrue(pointsAreConvex(vectors)) } // MARK: degeneracy func testDegenerateColinearVertices() { let normal = Vector(0, 0, 1) let vertices = [ Vertex(Vector(0, 1), normal), Vertex(Vector(0, 0), normal), Vertex(Vector(0, -2), normal), ] XCTAssertTrue(verticesAreDegenerate(vertices)) } func testNonDegenerateColinearVertices() { let normal = Vector(0, 0, 1) let vertices = [ Vertex(Vector(0, 1), normal), Vertex(Vector(0, 0), normal), Vertex(Vector(0, -2), normal), Vertex(Vector(1.5, -1), normal), ] XCTAssertFalse(verticesAreDegenerate(vertices)) } func testDegenerateVerticesWithZeroLengthEdge() { let normal = Vector(0, 0, 1) let vertices = [ Vertex(Vector(0, 1), normal), Vertex(Vector(0, -1), normal), Vertex(Vector(0, -1), normal), Vertex(Vector(1.5, 0), normal), ] XCTAssertTrue(verticesAreDegenerate(vertices)) } // MARK: path sanitization func testSanitizeInvalidClosedPath() { let points: [PathPoint] = [ .point(0, 1), .point(0, 0), .point(0, -1), .point(0, 1), ] let result = sanitizePoints(points) XCTAssertEqual(result.count, 3) XCTAssertEqual(result, [ .point(0, 1), .point(0, 0), .point(0, 1), ]) let result2 = sanitizePoints(result) XCTAssertEqual(result.count, result2.count) } func testRemoveZeroAreaColinearPointRemoved() { let points: [PathPoint] = [ .point(0.18, 0.245), .point(0.18, 0.255), .point(0.17, 0.255), .point(0.16, 0.247), .point(0.16, 0.244), .point(0.16, 0.245), .point(0.18, 0.245), ] let result = sanitizePoints(points) XCTAssertEqual(result.count, 6) XCTAssertEqual(result, [ .point(0.18, 0.245), .point(0.18, 0.255), .point(0.17, 0.255), .point(0.16, 0.247), .point(0.16, 0.245), .point(0.18, 0.245), ]) } } ```
Robert Smedley (born June 25, 1963, in Ashland, Kentucky) is an American retired professional wrestler and author, better known by his ring name Bobby Blaze. He gained the majority of his in-ring success performing for Smoky Mountain Wrestling (SMW) from 1993 to 1995, where he held the SMW Heavyweight Championship once, the SMW United States Junior Heavyweight Championship a record four times and the SMW Beat the Champ Television Championship twice. He also performed on the undercard in World Wrestling Federation (WWF) and World Championship Wrestling (WCW). Professional wrestling career Early career (1988–1993) Robert "Bob" Smedley made his professional wrestling debut on September 11, 1988, after training under Boris and Dean Malenko. In 1991 and 1992, he would wrestle as enhancement talent for the World Wrestling Federation (WWF). Smoky Mountain Wrestling (1993–1995) In 1993, Smedley began working for the newly formed Smoky Mountain Wrestling (SMW) under the ring name Bobby Blaze. On June 7, 1993, he won the SMW Beat the Champ Television Championship by defeating The Dirty White Boy in a tournament final. Twenty-one days later, Blaze faced an unknown, masked wrestler known as "The Mighty Yankee," which turned out to be the Dirty White Boy pulling a trick on Blaze to win the championship from him. Blaze was one of eight wrestlers competing in SMW's "King of Kentucky" tournament, defeating Killer Kyle in the first round before losing to Brian Lee in the semi-finals. In September, he won a tournament to become the inaugural SMW United States Junior Heavyweight Champion, a title he held for 21 days before Chris Candido won it from him. The title change led to a series of matches between the two, including trading the title back and forth between them. The two also faced off in a series of matches where the loser would be tarred and feathered after the match as part of SMW's Thanksgiving Thunder series. On February 26, 1995, in the main event of SMW's Sunday, Bloody Sunday II, show Blaze defeated Jerry Lawler to win the SMW Heavyweight Championship. He lost the title to Buddy Landel on April 8. Blaze held the SMW Beat the Champ Television Championship one last time before the promotion closed. He also had a couple shots at the NWA World Heavyweight Championship against Dan Severn on May 20 in Charlotte, North Carolina, and on August 4 in Knoxville, Tennessee. Post-SMW career (1995–1997) After SMW closed, Blaze wrestled on the independent circuit throughout the American East Coast, as well as touring Japan for Michinoku Pro Wrestling (MPW). World Championship Wrestling (1997–1999) In September 1997, Blaze joined World Championship Wrestling (WCW). He appeared in the 60-man battle royal in the main event of the World War 3 in 1997 and 1998. Blaze remained with the company, largely performing as a jobber in undercard matches, until 1999. Post-WCW career (1999–2004) After leaving WCW, Blaze returned to the American independent scene where he would remain active for five years before retiring in 2004. Since June 2018, Bobby has hosted a podcast called Bell to Bell with Bobby Blaze. Books Pin Me, Pay Me!: Have Boots, Will Travel I Kicked Out on Two: The Education of a Wrestler Championships and accomplishments Cleveland All Pro Wrestling CAPW North American Heavyweight Championship (2 times) Heartland Wrestling Association HWA Heavyweight Championship (1 time) Pro Wrestling Illustrated PWI ranked him #109 of the top 500 singles wrestlers in the PWI 500 in 1995. Smoky Mountain Wrestling SMW Beat the Champ Television Championship (3 times, final champion) SMW Heavyweight Championship (1 time) SMW United States Junior Heavyweight Championship (4 times, final champion) Southern States Wrestling SSW Junior Heavyweight Championship (1 time) Unleashed Wrestling Alliance UWA Hall of Fame (2013) References External links 1963 births American male professional wrestlers Living people Professional wrestlers from Kentucky Sportspeople from Ashland, Kentucky 20th-century professional wrestlers 21st-century professional wrestlers SMW Beat the Champ Television Champions SMW Heavyweight Champions SMW United States Junior Heavyweight Champions 1988 professional wrestling debuts
Corymbia calophylla – Xanthorrhoea preissii woodlands and shrublands of the Swan Coastal Plain is an ecological community in the Southwest Australia ecoregion. The assemblage, found inland on the eastern side of the Swan Coastal Plain, is defined by the presence of plant species at drier or lower rainfall areas of heavy soils dominated by several marri communities. The mid and upper story vegetation is the marri tree, Corymbia calophylla, and the grasstree Xanthorrhoea preissii, called balga. Marri is also found in two other described ecological communities which contain some plants of the assemblage, those in wetter areas of the range with a greater diversity of plants. The locations of these communities is a remnant of a previously greater range, having been reduced by possibly over 97%. The community is recognised by an association of species: trees are Corymbia calophylla and occasional Eucalyptus wandoo; shrubs are Acacia pulchella, Dryandra nivea (Banksia nivea), Gompholobium marginatum, Hypocalymma angustifolia and Xanthorrhoea preissii; the herbaceous plants are Burchardia umbellata, Cyathochaeta avenacea and Neurachne alopecuroidea. Threatened species are associated with this community, itself listed as endangered; the western swamp tortoise (Pseudemydura umbrina), critically endangered, occurs in and near the community, as do the rare plants Isopogon drummondii and fringed lily Thysanotus glaucus. References Swan Coastal Plain Endangered ecological communities Endangered biota of Australia
The 1949 Liège–Bastogne–Liège was the 35th edition of the Liège–Bastogne–Liège cycle race and was held on 1 May 1949. The race started and finished in Liège. The race was won by Camille Danguillaume. General classification References 1949 1949 in Belgian sport
Andrey Alyaksandravich Harbunow (; (Andrey Aleksandrovich Gorbunov); born 29 May 1983) is a Belarusian former professional footballer who played as a goalkeeper. Career Gorbunov made his debut for the Belarus national team on 30 March 2015, in a friendly match against Gabon. On 17 May 2017, he ended his contract with Atromitos F.C. after three consecutive years with the club. Honours BATE Borisov Belarusian Premier League champion: 2012, 2013 Belarusian Super Cup winner: 2013 References External links 1983 births Living people Footballers from Mogilev Belarusian men's footballers Men's association football goalkeepers Belarus men's international footballers Super League Greece players FC Dnepr Mogilev players FC Veino players FC Spartak Shklov players FC Dinamo Minsk players FC Neman Grodno players FC BATE Borisov players Atromitos F.C. players FC Torpedo-BelAZ Zhodino players Belarusian expatriate men's footballers Expatriate men's footballers in Greece
The Douglas County Library System (DCLS) was a public library system in Douglas County, Oregon, United States. The library system was founded in 1953 and operated eleven branches across Douglas County at the time of its closure in 2017. History Douglas County's first library was established in 1912 to serve Myrtle Creek. The Myrtle Creek library was followed by other local systems in Roseburg, Reedsport, Glendale, Drain, Yoncalla, and Sutherlin in the 1920s and 1930s. The Douglas County Library System was established in 1953, based in Roseburg and operating eight branches across the county. Two new libraries were built for Winston and Riddle in the 1960s, and in 1994, a new main branch was opened in Roseburg. The system was funded by the county government, which was heavily reliant on declining sales taxes on timber harvests on federal land, and began budget reductions in 1982. The expiration of the federal Secure Rural Schools program in 2015 further constrained funding for Douglas County, forcing the system to run on grants from the Ford Family Foundation until a public vote on funding could be held in 2016. The Douglas County Board of Commissioners voted in June 2016 to place a ballot measure asking to create a public library district and fund it using a property tax of 44 cents per $1,000 in assessed value. During the November 2016 election, the library ballot measure was rejected by 55 percent of Douglas County voters. After the failure of the ballot measure, the county government sought other funding solutions, opting to run through the end of June with funds from the county's general fund. The ten branch locations of the library system closed on April 1, 2017. The Roseburg main branch closed on May 31, 2017, and library supporters held a wake during its final evening in service. The Douglas County system became the third county library system in Oregon to be closed, after Jackson and Josephine counties closed their systems in 2007. Both systems later re-opened under non-government management in limited capacity. Branches At the time of its closure in 2017, the system operated eleven branches in the cities of Canyonville, Drain, Glendale, Myrtle Creek, Oakland, Reedsport, Riddle, Roseburg, Sutherlin, Winston, and Yoncalla. By the following year, nine branches had reopened under the care of volunteers with grants from city governments as well as private donations and fundraisers. The City of Roseburg reopened its library in January 2019, following a year of planning. References 1953 establishments in Oregon 2017 disestablishments in Oregon County library systems in Oregon Douglas County, Oregon Libraries established in 1953
Rolf Reine Almqvist (born 12 April 1949) is a Swedish former professional football player and coach who played as striker. Club career Almqvist played for IFK Göteborg, Åtvidabergs FF, IFK Sundsvall, In 1980, he joined the Seattle Sounders of the North American Soccer League, playing five games during the outdoor season and another seventeen during the 1980–81 NASL indoor season. He then returned to Sweden and played for BK Häcken, Ope IF and Djerv 1919. He was the Allsvenskan top scorer in 1969 and 1977. International career Almqvist won four caps and scored one goal between 1970 and 1979 for the Sweden national team. He also represented the Sweden U19 and U21 teams. Managerial career Almqvist coached IF Olsfors, Kullens BK, BK Häcken, Djerv 1919, Fredrikstad FK, Helsingborgs IF, IFK Göteborg, Landskrona BoIS, Bryne, FK Tønsberg and Västra Frölunda IF. Career statistics International Scores and results list Sweden's goal tally first, score column indicates score after each Almqvist goal. Honours IFK Göteborg Allsvenskan: 1969 Åtvidabergs FF Allsvenskan: 1973 Individual Allsvenskan top scorer: 1969, 1977 References External links Seattle Sounders stats 1949 births Living people Swedish men's footballers Footballers from Gothenburg Men's association football forwards Sweden men's international footballers Allsvenskan players IFK Göteborg players Åtvidabergs FF players IFK Sundsvall players Seattle Sounders (1974–1983) players BK Häcken players SK Djerv 1919 players North American Soccer League (1968–1984) indoor players North American Soccer League (1968–1984) players Swedish football managers BK Häcken managers Fredrikstad FK managers Helsingborgs IF managers IFK Göteborg managers Landskrona BoIS managers Bryne FK managers Halmstads BK non-playing staff Swedish expatriate men's footballers Swedish expatriate football managers Swedish expatriate sportspeople in the United States Expatriate men's soccer players in the United States Swedish expatriate sportspeople in Norway Expatriate men's footballers in Norway Expatriate football managers in Norway
Guilderland Central School District (GCSD) is a school district encompassing most of the Town of Guilderland and parts of Bethlehem, New Scotland, and Knox. The district serves approximately 4,828 K-12 students across seven school buildings. Schools The district consists of five elementary schools, one middle school, and one high school. Altamont Elementary School (constructed 1953) Guilderland Elementary School (constructed 1955) Lynnwood Elementary School (constructed 1968) Pine Bush Elementary School (constructed 1994) Westmere Elementary School (constructed 1953) Farnsworth Middle School (constructed 1970) Guilderland High School (constructed 1953) Construction and renovations The Pine Bush Elementary School on Carman Road, Route 146, opened in September 1994. It was approved by the community due to the district's growing enrollment. In 1999, a major expansion and renovation project, supported by a $24 million bond issue, was completed at Guilderland High School. In October 2001, voters approved the expansion and renovation of Farnsworth Middle School—a $19.7 million project which was completed in September 2005. This project included a fourth gym and the entire Seneca House. References External links Guilderland Central School District Guilderland, New York School districts in Albany County, New York
Universality most commonly refers to: Universality (philosophy) Universality (dynamical systems) Universality principle may refer to: In statistics, universality principle, a property of systems that can be modeled by random matrices In law, as a synonym for universal jurisdiction In moral philosophy, the first formulation of Kant's categorical imperative. Universality may also refer to several concepts that are also known as "universality" Background independence, a concept of universality in physical science Turing-complete, a concept of universality in computation Universal property, a mathematical concept Universal jurisdiction, in international law Lepton universality in the Standard Model of particle physics. Universality of the Church, a theological concept in Christian ecclesiology See also Universal (disambiguation) Universalism (disambiguation) Universality probability Universalization Universalizability
Rev Dr. William Nicol (23 March 1887, in Robertson – 22 June 1967) was a Dutch Reformed minister, theologian, educator and Administrator of the Transvaal Province of South Africa. Life In 1906, he obtained his bachelor's degree at Stellenbosch University and then studied at the Free University of Amsterdam and Princeton. From 1913 to 1938 he was a minister of the Dutch Reformed Church in Johannesburg East, called Irene Church. In June 1938, he became a minister in Pretoria East. From 1934 to 1948 he was the moderator of the Dutch Reformed Synod of the Transvaal. In Johannesburg, he was a champion for the recognition of the Afrikaans language and the establishment of Afrikaans-medium schools. Nicol was the founder of Johannesburg East's parish magazine, Irenenuus, in January 1923, that he wanted the members in their particular situation escorted to their faith. It was written in Afrikaans in a time when the language just started gaining a foothold in schools and was rarely heard from the pulpit. Nicol in August 1923 (date uncertain) made history when he wrote the first sermon in Afrikaans broadcast on the radio directly into the radio studios in downtown Johannesburg. At 9:45 on Sunday, 7 June 1924, the minister and church made history when full service was held in Afrikaans for the first time. He also broadcast on the Union broadcast and from Irene Hall. A month later, on 4 October 1925, the first communion service was broadcast from Irene Hall led by Nicol. He was the second chairman of the Afrikaner Broederbond from 1924-1925. On 1 November 1948 he was elected as the administrator of Transvaal and ten years later his work, especially with regard to education and culture, continued to grow. He retired on 1 October 1958. Nicol believed in teaching education in the person's mother tongue and said any education taught in a second language would hinder a person's growth and learning ability. Thus he also helped translate the Bible with help from African religious leaders into Zulu. He opposed the National Party's Bantu Education and suggested a model with learning in the mother tongue with English as a second language so that people could all communicate. Legacy A number of roads in South Africa were named after Nicol, most notably William Nicol Drive in the Northern suburbs of Johannesburg. On 26 September, 2023 the road was renamed to Winnie Mandela Drive. This resulted in controversy, with the Afrikanerbond, a successor of the Broederbond slamming the ruling party, The ANC, for attempting to rewrite history. Nicol is considered as one of the architects of apartheid and co-authored a book, 'Regverdige Rasse-Apartheid', which translates as Just Racial Apartheid Which calls for the creation of Apartheid with attempts at religious justifications. Works Book Regverdige Rasse-Apartheid. Stellenbosch: CSV-Boekhandel, 1947. (co-author with E.P. Groenewald and G. Cronjé). References [3] Stellenbosch University alumni Princeton University alumni Dutch Reformed Church missionaries 1887 births 1967 deaths National Party (South Africa) politicians People from Johannesburg 3. hDaily Maverick. JRChronologizer, Retrieved 23 September 2023
The Rocketplane XP was a suborbital spaceplane design that was under development c. 2005 by Rocketplane Kistler. The vehicle was to be powered by two jet engines and a rocket engine, intended to enable it to reach suborbital space. The XP would have operated from existing spaceports in a manner consistent with established commercial aviation practices. Commercial flights were projected to begin in 2009. Rocketplane Global declared bankruptcy in mid-June 2010. Their assets were auctioned off in 2011. Design and development As envisioned, the Rocketplane XP would carry a pilot and five passengers on a flight profile from a runway using jet engines like a conventional aircraft. It would then climb to about 12 km (40,000 feet). At this point, a reusable rocket engine would power the XP on a suborbital trajectory reaching altitudes of over after burnout. The XP was to then reenter Earth's atmosphere and land at the same spaceport under conventional jet power. The relatively low speeds involved meant that heat shielding was not a major concern. The XP was expected to operate from the Clinton-Sherman Industrial Airpark near Burns Flat, Oklahoma. On January 24, 2006 Rocketplane Limited announced a Space Act agreement with NASA Johnson Space Center for the loan of a Rocketdyne RS-88 rocket engine for three years, for use in flight tests of the XP vehicle. See also EADS Astrium Space Tourism Project Lynx (spacecraft) Dream Chaser SpaceShipTwo Blue Origin New Shepard References Notes Bibliography Belfiore, Michael. "It's a Rocket! It's a Plane! It's...Rocket Plane!" Popular Science, January 8, 2006. "Model XP Specifications." Rocketplane XP, February 21, 2011. External links Rocketplane official website astronautix.com Video animation - Rocketplane XP concept Mixed-power aircraft Rocket-powered aircraft Spaceplanes Abandoned civil aircraft projects of the United States XP Low-wing aircraft
The Phoenix Elementary School District #1 (PESD) is a kindergarten through 8th grade school district in Phoenix, Arizona, United States. It was established in 1871 as the first free public school district in Arizona. The district boundaries cover an area from 16th Street on the east, south of Buckeye Road on the south, past 23rd Avenue on the west and Thomas Road on the north. Student services include: speech and language therapy, social and psychological services, services for the hearing and visually impaired, gifted education, and special education. Each school has a nurse or nurse's assistant on staff. Students of working parents are offered free before and after school care for their students. As of 2016 the superintendent is Mr. Larry Weeks Students feed into the Phoenix Union High School District. In 2015 the district considered closing Shaw Elementary School due to a deficit of over $800,000. Elementary schools Bethune Capitol Dunbar Edison Emerson Faith North Preschool Garfield Heard Herrera Kenilworth Lowell Magnet Traditional School Shaw Montessori Whittier References External links Official website School districts in Phoenix, Arizona School districts in Maricopa County, Arizona 1871 establishments in Arizona Territory School districts established in 1871
The Revolution Starts Now may refer to: The Revolution Starts Now (album), a 2004 album by Steve Earle "The Revolution Starts Now" (song), a song on the 2004 album by Steve Earle The Steve Earle Show, an American radio show formerly known as The Revolution Starts Now that last aired in 2007
Lunugamwehera is a small town in Sri Lanka. It is located within Southern Province. See also List of towns in Southern Province, Sri Lanka External links Populated places in Southern Province, Sri Lanka
Edson Borges (born January 20, 1985), is a Brazilian defender. He currently plays for Santa Cruz. External links Ogol Soccerway Sambafoot Grupo Empenho 1985 births Living people Brazilian men's footballers Santa Cruz Futebol Clube players Santos FC Men's association football forwards Footballers from Santa Catarina (state)
The Mark Spencer Hotel is a hotel in Portland, Oregon. The hotel opened in 1907 as the Hotel Nortonia and has hosted many notable people, including Louis Armstrong, Sammy Davis Jr., Lionel Hampton, Spike Jones, and Mel Tormé. References 1907 establishments in Oregon Hotel buildings completed in 1907 Hotels in Portland, Oregon Southwest Portland, Oregon
```c++ // -*- C++ -*- // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the terms // Foundation; either version 2, or (at your option) any later // version. // This library is distributed in the hope that it will be useful, but // WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU // along with this library; see the file COPYING. If not, write to // the Free Software Foundation, 59 Temple Place - Suite 330, Boston, // MA 02111-1307, USA. // As a special exception, you may use this file as part of a free // software library without restriction. Specifically, if other files // instantiate templates or use macros or inline functions from this // file, or you compile this file and link it with other files to // produce an executable, this file does not by itself cause the // resulting executable to be covered by the GNU General Public // reasons why the executable file might be covered by the GNU General // Permission to use, copy, modify, sell, and distribute this software // is hereby granted without fee, provided that the above copyright // notice appears in all copies, and that both that copyright notice // and this permission notice appear in supporting documentation. None // of the above authors, nor IBM Haifa Research Laboratories, make any // representation about the suitability of this software for any // purpose. It is provided "as is" without express or implied // warranty. /** * @file cc_hash_max_collision_check_resize_trigger_imp.hpp * Contains a resize trigger implementation. */ #define PB_DS_STATIC_ASSERT(UNIQUE, E) \ typedef detail::static_assert_dumclass<sizeof(detail::static_assert<(bool)(E)>)> UNIQUE##static_assert_type PB_DS_CLASS_T_DEC PB_DS_CLASS_C_DEC:: cc_hash_max_collision_check_resize_trigger(float load) : m_load(load), m_size(0), m_num_col(0), m_max_col(0), m_resize_needed(false) { } PB_DS_CLASS_T_DEC inline void PB_DS_CLASS_C_DEC:: notify_find_search_start() { } PB_DS_CLASS_T_DEC inline void PB_DS_CLASS_C_DEC:: notify_find_search_collision() { } PB_DS_CLASS_T_DEC inline void PB_DS_CLASS_C_DEC:: notify_find_search_end() { } PB_DS_CLASS_T_DEC inline void PB_DS_CLASS_C_DEC:: notify_insert_search_start() { m_num_col = 0; } PB_DS_CLASS_T_DEC inline void PB_DS_CLASS_C_DEC:: notify_insert_search_collision() { ++m_num_col; } PB_DS_CLASS_T_DEC inline void PB_DS_CLASS_C_DEC:: notify_insert_search_end() { calc_resize_needed(); } PB_DS_CLASS_T_DEC inline void PB_DS_CLASS_C_DEC:: notify_erase_search_start() { } PB_DS_CLASS_T_DEC inline void PB_DS_CLASS_C_DEC:: notify_erase_search_collision() { } PB_DS_CLASS_T_DEC inline void PB_DS_CLASS_C_DEC:: notify_erase_search_end() { } PB_DS_CLASS_T_DEC inline void PB_DS_CLASS_C_DEC:: notify_inserted(size_type) { } PB_DS_CLASS_T_DEC inline void PB_DS_CLASS_C_DEC:: notify_erased(size_type) { m_resize_needed = true; } PB_DS_CLASS_T_DEC void PB_DS_CLASS_C_DEC:: notify_cleared() { m_resize_needed = false; } PB_DS_CLASS_T_DEC inline bool PB_DS_CLASS_C_DEC:: is_resize_needed() const { return m_resize_needed; } PB_DS_CLASS_T_DEC inline bool PB_DS_CLASS_C_DEC:: is_grow_needed(size_type /*size*/, size_type /*num_used_e*/) const { return m_num_col >= m_max_col; } PB_DS_CLASS_T_DEC void PB_DS_CLASS_C_DEC:: notify_resized(size_type new_size) { m_size = new_size; #ifdef PB_DS_HT_MAP_RESIZE_TRACE_ std::cerr << "chmccrt::notify_resized " << static_cast<unsigned long>(new_size) << std::endl; #endif calc_max_num_coll(); calc_resize_needed(); m_num_col = 0; } PB_DS_CLASS_T_DEC void PB_DS_CLASS_C_DEC:: calc_max_num_coll() { // max_col <-- \sqrt{2 load \ln( 2 m \ln( m ) ) } const double ln_arg = 2 * m_size * ::log(double(m_size)); m_max_col = size_type(::ceil(::sqrt(2 * m_load * ::log(ln_arg)))); #ifdef PB_DS_HT_MAP_RESIZE_TRACE_ std::cerr << "chmccrt::calc_max_num_coll " << static_cast<unsigned long>(m_size) << " " << static_cast<unsigned long>(m_max_col) << std::endl; #endif } PB_DS_CLASS_T_DEC void PB_DS_CLASS_C_DEC:: notify_externally_resized(size_type new_size) { notify_resized(new_size); } PB_DS_CLASS_T_DEC void PB_DS_CLASS_C_DEC:: swap(PB_DS_CLASS_C_DEC& other) { std::swap(m_load, other.m_load); std::swap(m_size, other.m_size); std::swap(m_num_col, other.m_num_col); std::swap(m_max_col, other.m_max_col); std::swap(m_resize_needed, other.m_resize_needed); } PB_DS_CLASS_T_DEC inline float PB_DS_CLASS_C_DEC:: get_load() const { PB_DS_STATIC_ASSERT(access, external_load_access); return m_load; } PB_DS_CLASS_T_DEC inline void PB_DS_CLASS_C_DEC:: calc_resize_needed() { m_resize_needed = m_resize_needed || m_num_col >= m_max_col; } PB_DS_CLASS_T_DEC void PB_DS_CLASS_C_DEC:: set_load(float load) { PB_DS_STATIC_ASSERT(access, external_load_access); m_load = load; calc_max_num_coll(); calc_resize_needed(); } #undef PB_DS_STATIC_ASSERT ```
Frane Ikić (born 19 June 1994) is a Croatian professional footballer who plays as a centre-back for Uzbekistan Super League club Buxoro. Club career Ikić made his professional debut for Zadar on 17 November 2012, coming on as a substitute. In his first three seasons with Zadar in the 1. HNL he scored 2 goals in 44 appearances. On 15 July 2015, he signed a two-year contract with Rijeka, with the possibility of an additional two-year extension. On 19 January 2017, Ikić joined Slovenian PrvaLiga club Koper. After appearing in just one match for Koper, Ikić left the club and joined Cibalia. After Cibalia, he returned to and had a brief spell at Zadar. In summer 2019, he returned to Slovenia and joined Fužinar. On 1 February 2020, Ikić signed a six month contract with a possibility of an extension with Bosnian Premier League club Željezničar. He made his official debut for Željezničar in a 3–0 win against Zvijezda 09 on 29 February 2020. On 6 June 2020, Ikić extended his contract with Željezničar, which is due to last until June 2021. Ikić scored his first goal for Željezničar on 28 October 2020, in a league match against Zrinjski Mostar. He left Željezničar in June 2021. International career Ikić represented Croatia at various youth levels between 2013 and 2015. Honours Rijeka 1. HNL runner-up: 2015–16 Željezničar Bosnian Premier League runner-up: 2019–20 References External links Frane Ikić at Sofascore 1994 births Living people Footballers from Zadar Men's association football central defenders Croatian men's footballers Croatia men's youth international footballers Croatia men's under-21 international footballers NK Zadar players HNK Rijeka players HNK Rijeka II players FC Koper players HNK Cibalia players NK Fužinar players FK Željezničar Sarajevo players Gyirmót FC Győr players FK Velež Mostar players Croatian Football League players First Football League (Croatia) players Slovenian PrvaLiga players Slovenian Second League players Premier League of Bosnia and Herzegovina players Nemzeti Bajnokság I players Croatian expatriate men's footballers Expatriate men's footballers in Slovenia Croatian expatriate sportspeople in Slovenia Expatriate men's footballers in Bosnia and Herzegovina Croatian expatriate sportspeople in Bosnia and Herzegovina Expatriate men's footballers in Hungary Croatian expatriate sportspeople in Hungary
The 2004 European Women Sevens Championship was the third edition of the European Women's Sevens Championship. Qualification Tournament Venue/Date: Prague, 14–15 May 2005 Bosnia failed to appear and were replaced by Czech Republic II. All results. Group A Bulgaria 26-7 Israel Poland 7-42 Germany Lithuania 38-0 Austria Germany 45-0 Israel Bulgaria 12-5 Austria Lithuania 15-7 Poland Austria 5-0 Israel Lithuania 0-19 Germany Poland 7-12 Bulgaria Germany 52-0 Austria Poland 12-0 Israel Lithuania 12-5 Bulgaria Poland 19-0 Austria Bulgaria 0-28 Germany Lithuania 33-0 Israel Group B Czech Republic B 0-10 Malta Norway 0-28 Russia Czech Republic A 7-19 Hungary Russia 43-5 Malta Czech Republic B 0-7 Hungary Czech Republic A 0-7 Norway Hungary 10-0 Malta Czech Republic A 0-34 Russia Norway 40-0 Czech Republic B Russia 47-0 Hungary Norway 21-0 Malta Czech Republic A 17-0 Czech Republic B Norway 7-0 Hungary Czech Republic B 0-50 Russia Czech Republic A 5-0 Malta Classification Stages FIRA Women's European Championship Venue/Date: Lunel, France, 25–26 June 2005'' Summarised Pool Stages POOL A Portugal 12-12 Belgium England 54-0 Switzerland Spain 40-0 Portugal Belgium 12-0 Switzerland England 12-7 Spain Portugal 22-5 Switzerland Spain 24-0 Belgium England 28-0 Portugal Spain 43-0 Switzerland England 21-0 Belgium POOL B Netherlands 28-0 Croatia Sweden 21-0 Italy France 12-0 Croatia Netherlands 19-0 Sweden France 31-0 Italy Sweden 21-0 Croatia Netherlands 7-5 France Italy 12-5 Croatia Sweden 7-5 France Netherlands 35-0 Italy Classification Stages Plate Semi-finals France 22-0 Portugal Italy 19-7 Belgium Cup Semi-finals Spain 28-5 Netherlands England 49-0 Sweden 9th Place Croatia 7-5 Switzerland 7th Place Portugal 35-10 Belgium 5th Place (Plate) France 33-0 Italy 3rd Place Netherlands 21-7 Sweden Cup Final England 14-0 Spain References 2005 2005 rugby sevens competitions sevens 2004–05 in French rugby union International women's rugby union competitions hosted by France rugby union
Pellucida is a genus of fungi in the family Hyponectriaceae. This is a monotypic genus, containing the single species Pellucida pendulina. References External links Index Fungorum Xylariales Monotypic Ascomycota genera
USS Ohio was a schooner "launched at Cleveland in 1810 by merchants named Murray and Bigsbey." purchased by the US Navy in 1812; converted to a warship by Henry Eckford; and commissioned prior to 13 June 1813, with Sailing Master Daniel Dobbins in command. Ohio served on Lake Erie in the squadron commanded by Captain Oliver Hazard Perry during the War of 1812. The squadron's mission was to wrest control of the lake from the British. With four other purchased ships, Ohio lay at Black Rock below the Falls in the Niagara River, prevented by British blockade from entering Lake Erie. Finally, in a combined operation with the Army, Perry was able to bring the ships out to join the remainder of the squadron in Presque Isle Bay at Erie, Pennsylvania. Ohio arrived at Erie on 8 July 1813. After searching for the British, the squadron anchored at Sandusky on 17 August. Ohio returned to Erie for provisions and stores for the squadron, rejoining her sister ships on 3 September. The same day she set sail for Erie again, and thus was not with the squadron when it won the memorable victory over the British at Put-in Bay on 10 September. Three days later Ohio reached Put-in Bay with sorely needed fresh vegetables and meat. As soon as the ice cleared in early 1814, Ohio began patrolling between Long Point and Erie to intercept any British movement by water. In May she assisted in fitting out prizes and at Put-in Bay, and convoyed them to Erie. On 12 August 1814, Ohio was captured along with the schooner by the British within pistol shot of Fort Erie. Somers was renamed Huron while Ohio was renamed Sauk. "[T]he Sauk (ex-Ohio) and Huron (ex-Somers) were taken up Chippewa Creek and submerged in one of its tributaries, Street's Creek, just in case the American tried to recapture them in a raid across the Niagara." The schooners were raised and refitted in the spring of 1815. They both wintered at the Royal Navy station at the mouth of the Grand River. The Ohio's subsequent history is unknown after 1817. References Schooners of the United States Navy War of 1812 ships of the United States Great Lakes ships History of Erie, Pennsylvania 1810 ships War of 1812 ships of the United Kingdom Vessels captured from the United States Navy
```shell #!/usr/bin/env bash # # SIMULATION_ID="cap_unicast_ac_7_i" VERBOSITY_LEVEL=2 EXECUTE_TIMEOUT=60 source ${ZEPHYR_BASE}/tests/bsim/sh_common.source cd ${BSIM_OUT_PATH}/bin function Execute_AC_7_I() { printf "\n\n======== Running CAP AC_7_I with %s =========\n\n" $1 Execute ./bs_${BOARD_TS}_tests_bsim_bluetooth_audio_prj_conf \ -v=${VERBOSITY_LEVEL} -s=${SIMULATION_ID} -d=0 -testid=cap_initiator_ac_7_i \ -RealEncryption=1 -rs=23 -D=2 -argstest sink_preset $1 source_preset $2 Execute ./bs_${BOARD_TS}_tests_bsim_bluetooth_audio_prj_conf \ -v=${VERBOSITY_LEVEL} -s=${SIMULATION_ID} -d=1 -testid=cap_acceptor_unicast \ -RealEncryption=1 -rs=46 -D=2 # Simulation time should be larger than the WAIT_TIME in common.h Execute ./bs_2G4_phy_v1 -v=${VERBOSITY_LEVEL} -s=${SIMULATION_ID} \ -D=2 -sim_length=60e6 ${@:3} wait_for_background_jobs } set -e # Exit on error Execute_AC_7_I 8_1_1 8_1_1 Execute_AC_7_I 8_2_1 8_2_1 Execute_AC_7_I 16_1_1 16_1_1 Execute_AC_7_I 16_2_1 16_2_1 Execute_AC_7_I 24_1_1 24_1_1 Execute_AC_7_I 24_2_1 24_2_1 Execute_AC_7_I 32_1_1 32_1_1 Execute_AC_7_I 32_2_1 32_2_1 Execute_AC_7_I 441_1_1 441_1_1 Execute_AC_7_I 441_2_1 441_2_1 Execute_AC_7_I 48_1_1 48_1_1 Execute_AC_7_I 48_2_1 48_2_1 Execute_AC_7_I 48_3_1 48_3_1 Execute_AC_7_I 48_4_1 48_4_1 Execute_AC_7_I 48_5_1 48_5_1 Execute_AC_7_I 48_6_1 48_6_1 ```
Bernard F. Schutz FInstP FLSW (born August 11, 1946, in Paterson, New Jersey) is an American and naturalised British physicist. He is well known for his research in Einstein's theory of general relativity, especially for his contributions to the detection of gravitational waves, and for his textbooks. Schutz is a Fellow of the Royal Society and a Member of the US National Academy of Sciences. He is a professor of physics and astronomy at Cardiff University, and was a founding director of the Max Planck Institute for Gravitational Physics (Albert Einstein Institute) in Potsdam, Germany, where he led the Astrophysical Relativity division from 1995 to 2014. Schutz was a founder and principal investigator of the GEO gravitational wave collaboration, which became part of the LIGO Scientific Collaboration (LSC). Schutz was also one of the initiators of the proposal for the space-borne gravitational wave detector LISA (Laser Interferometer Space Antenna), and he coordinated the European planning for its data analysis until the mission was adopted by ESA in 2016. Schutz conceived and in 1998 began publishing from the AEI the online open access (OA) review journal Living Reviews in Relativity, which for many years has been the highest-impact OA journal in the world, as measured by Clarivate. (The journal is now published by Springer.) Honors Schutz received the 2019 Eddington Medal of the Royal Astronomical Society (RAS) and the 2006 Amaldi Gold Medal from the Italian Society for Gravitation (SIGRAV), shared the 2020 Richard A. Isaacson Award of the American Physical Society (APS), and was awarded an honorary DSc by the University of Glasgow in 2011. In 2011, he was also elected a Fellow of the Learned Society of Wales. Bibliography References External links Astrophysics Group at the Albert Einstein Institute Living people 1946 births 21st-century American physicists American relativity theorists Max Planck Society people Clarkson University alumni California Institute of Technology alumni Members of the United States National Academy of Sciences Max Planck Institute directors Fellows of the Learned Society of Wales
Operation Sukoon (Hindi, lit relief) was an operation launched by the Indian Navy to evacuate Indian, Sri Lankan and Nepalese nationals, as well as Lebanese nationals with Indian spouses, from the conflict zone during the 2006 Lebanon War. The Indian Armed Forces also launched a similar effort, Operation Safe Homecoming, to bring Indian nationals from Libya during the 2011 Libyan civil war. Background Military conflict between Israel and the Hezbollah broke out in July–August 2006, when on 12 July, Hezbollah launched a cross-border raid into Israel, in which 10 Israeli soldiers were killed, and two of their bodies were captured to be used to bargain for the release of Lebanese prisoners in Israel. Israel responded with an aerial and maritime blockade, and a massive bombing campaign and ground invasion of Lebanon. During the war, numerous foreign nationals visiting Lebanon were caught in the conflict. One Indian citizen was killed and three wounded on 21 July in an Israeli bombing attack. The Government of India asked the Indian Armed Forces to help evacuate its citizens at risk from the conflict zone. Of the over 10,000 Indian nationals in Lebanon, almost 2,000 were at risk. Neighbouring Sri Lanka and Nepal, which lacked military resources, also requested the Indian government to help evacuate their citizens. Altogether, over 2,200 nationals of these countries were caught in the conflict zone. Response Indian Navy Task Force 54, consisting of three warships and a fleet tanker, was returning to India from the Mediterranean following a goodwill visit and was just about to cross the Suez Canal. Following the hostilities, it was ordered to turn back to help evacuate Indian nationals from Lebanon. The task force comprised the destroyer , the frigates , and the fleet tanker INS Shakti. The plan for the evacuation was for the warships were to take the evacuees to Cyprus, from where chartered Air India flights would fly them back to India. The warships were on high alert at battle stations. The task force's seven helicopters were airborne to detect and intercept any of the belligerent forces mistaking the Indian vessels for their enemy. Mumbai evacuated 1,495 people to Cyprus, in three sorties on 20, 23 and 26 July. Brahmaputra and Betwa evacuated 188 and 254 people, respectively, during a sortie on 23 July. Shakti was not deployed for a front-line evacuation since that vessel was more vulnerable without rapid reaction defence systems and less manoeuvrable. However, the support ship helped provide fuel and provisions for the evacuees on board the other ships during the operation. Altogether a total of 2,280 people including 1,764 Indians were evacuated. 112 Sri Lankans, 64 Nepalese and seven Lebanese nationals with Indian spouses were also among the evacuees. Citizens of other friendly nations at risk were also evacuated as a courtesy. This was one of the largest evacuation operations conducted by the Indian Navy since World War II. After the evacuation, the task force remained on station in international waters off Lebanon, monitoring the conflict, and ensuring the safety of remaining Indian nationals in Lebanon. The vessels left for their home ports on 10 August 2006. References 2006 Lebanon War Non-combat military operations involving India 2006 in India Evacuations of Indians Airlifts Non-combatant evacuation operations
```markdown TSG034 - Livy logs ================== Description ----------- Steps ----- ### Parameters``` ```python import re tail_lines = 2000 pod = None # All container = 'hadoop-livy-sparkhistory' log_files = [ '/var/log/supervisor/log/livy*' ] expressions_to_analyze = [ re.compile(".{17} WARN "), re.compile(".{17} ERROR ") ] ``` ```markdown ### Instantiate Kubernetes client``` ```python # Instantiate the Python Kubernetes client into 'api' variable import os try: from kubernetes import client, config from kubernetes.stream import stream if "KUBERNETES_SERVICE_PORT" in os.environ and "KUBERNETES_SERVICE_HOST" in os.environ: config.load_incluster_config() else: config.load_kube_config() api = client.CoreV1Api() print('Kubernetes client instantiated') except ImportError: from IPython.display import Markdown display(Markdown(f'HINT: Use [SOP059 - Install Kubernetes Python module](../install/sop059-install-kubernetes-module.ipynb) to resolve this issue.')) raise ``` ```markdown ### Get the namespace for the big data cluster Get the namespace of the big data cluster from the Kuberenetes API. NOTE: If there is more than one big data cluster in the target Kubernetes cluster, then set \[0\] to the correct value for the big data cluster.``` ```python # Place Kubernetes namespace name for BDC into 'namespace' variable try: namespace = api.list_namespace(label_selector='MSSQL_CLUSTER').items[0].metadata.name except IndexError: from IPython.display import Markdown display(Markdown(f'HINT: Use [TSG081 - Get namespaces (Kubernetes)](../monitor-k8s/tsg081-get-kubernetes-namespaces.ipynb) to resolve this issue.')) display(Markdown(f'HINT: Use [TSG010 - Get configuration contexts](../monitor-k8s/tsg010-get-kubernetes-contexts.ipynb) to resolve this issue.')) display(Markdown(f'HINT: Use [SOP011 - Set kubernetes configuration context](../common/sop011-set-kubernetes-context.ipynb) to resolve this issue.')) raise print('The kubernetes namespace for your big data cluster is: ' + namespace) ``` ```markdown ### Get tail for log``` ```python # Display the last 'tail_lines' of files in 'log_files' list pods = api.list_namespaced_pod(namespace) entries_for_analysis = [] for p in pods.items: if pod is None or p.metadata.name == pod: for c in p.spec.containers: if container is None or c.name == container: for log_file in log_files: print (f"- LOGS: '{log_file}' for CONTAINER: '{c.name}' in POD: '{p.metadata.name}'") try: output = stream(api.connect_get_namespaced_pod_exec, p.metadata.name, namespace, command=['/bin/sh', '-c', f'tail -n {tail_lines} {log_file}'], container=c.name, stderr=True, stdout=True) except Exception: print (f"FAILED to get LOGS for CONTAINER: {c.name} in POD: {p.metadata.name}") else: for line in output.split(' '): for expression in expressions_to_analyze: if expression.match(line): entries_for_analysis.append(line) print(line) print("") print(f"{len(entries_for_analysis)} log entries found for further analysis.") ``` ```markdown ### Analyze log entries and suggest relevant Troubleshooting Guides``` ```python # Analyze log entries and suggest further relevant troubleshooting guides from IPython.display import Markdown import os import json import requests import ipykernel import datetime from urllib.parse import urljoin from notebook import notebookapp def get_notebook_name(): """ Return the full path of the jupyter notebook. Some runtimes (e.g. ADS) have the kernel_id in the filename of the connection file. If so, the notebook name at runtime can be determined using `list_running_servers`. Other runtimes (e.g. azdata) do not have the kernel_id in the filename of the connection file, therefore we are unable to establish the filename """ connection_file = os.path.basename(ipykernel.get_connection_file()) # If the runtime has the kernel_id in the connection filename, use it to # get the real notebook name at runtime, otherwise, use the notebook # filename from build time. try: kernel_id = connection_file.split('-', 1)[1].split('.')[0] except: pass else: for servers in list(notebookapp.list_running_servers()): try: response = requests.get(urljoin(servers['url'], 'api/sessions'), params={'token': servers.get('token', '')}, timeout=.01) except: pass else: for nn in json.loads(response.text): if nn['kernel']['id'] == kernel_id: return nn['path'] def load_json(filename): with open(filename, encoding="utf8") as json_file: return json.load(json_file) def get_notebook_rules(): """ Load the notebook rules from the metadata of this notebook (in the .ipynb file) """ file_name = get_notebook_name() if file_name == None: return None else: j = load_json(file_name) if "azdata" not in j["metadata"] or \ "expert" not in j["metadata"]["azdata"] or \ "log_analyzer_rules" not in j["metadata"]["azdata"]["expert"]: return [] else: return j["metadata"]["azdata"]["expert"]["log_analyzer_rules"] rules = get_notebook_rules() if rules == None: print("") print(f"Log Analysis only available when run in Azure Data Studio. Not available when run in azdata.") else: hints = 0 if len(rules) > 0: for entry in entries_for_analysis: for rule in rules: if entry.find(rule[0]) != -1: print (entry) display(Markdown(f'HINT: Use [{rule[2]}]({rule[3]}) to resolve this issue.')) hints = hints + 1 print("") print(f"{len(entries_for_analysis)} log entries analyzed (using {len(rules)} rules). {hints} further troubleshooting hints made inline.") ``` ```python print('Notebook execution complete.') ```
```javascript /** * @license Apache-2.0 * * * * path_to_url * * Unless required by applicable law or agreed to in writing, software * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */ 'use strict'; // MAIN // /** * Tests if two double-precision floating-point numbers are the same value. * * ## Notes * * - The function implements the SameValueZero Algorithm used by `TypedArray` and `ArrayBuffer` constructors, `Map` and `Set` operations, `String.prototype.includes`, and `Array.prototype.includes` since ES2016. * - In contrast to the strict equality operator `===`, `NaNs` are considered the same value. * * @param {number} a - first input value * @param {number} b - second input value * @returns {boolean} boolean indicating whether two double-precision floating-point numbers are the same value * * @example * var bool = isSameValueZero( 3.14, 3.14 ); * // returns true * * @example * var bool = isSameValueZero( -0.0, -0.0 ); * // returns true * * @example * var bool = isSameValueZero( -0.0, 0.0 ); * // returns true * * @example * var bool = isSameValueZero( NaN, NaN ); * // returns true */ function isSameValueZero( a, b ) { return ( a === b ) || ( a !== a && b !== b ); // handles NaNs } // EXPORTS // module.exports = isSameValueZero; ```
```objective-c // // UIImagePickerControllerRACSupportSpec.m // ReactiveObjC // // Created by Timur Kuchkarov on 17.04.14. // @import Quick; @import Nimble; #import "UIImagePickerController+RACSignalSupport.h" #import "RACSignal.h" QuickSpecBegin(UIImagePickerControllerRACSupportSpec) qck_describe(@"UIImagePickerController", ^{ __block UIImagePickerController *imagePicker; qck_beforeEach(^{ imagePicker = [[UIImagePickerController alloc] init]; expect(imagePicker).notTo(beNil()); }); qck_it(@"sends the user info dictionary after confirmation", ^{ __block NSDictionary *selectedImageUserInfo = nil; [imagePicker.rac_imageSelectedSignal subscribeNext:^(NSDictionary *userInfo) { selectedImageUserInfo = userInfo; }]; NSDictionary *info = @{ UIImagePickerControllerMediaType: @"public.image", UIImagePickerControllerMediaMetadata: @{} }; [imagePicker.delegate imagePickerController:imagePicker didFinishPickingMediaWithInfo:info]; expect(selectedImageUserInfo).to(equal(info)); }); qck_it(@"cancels image picking process", ^{ __block BOOL didSend = NO; __block BOOL didComplete = NO; [imagePicker.rac_imageSelectedSignal subscribeNext:^(NSDictionary *userInfo) { didSend = YES; } completed:^{ didComplete = YES; }]; [imagePicker.delegate imagePickerControllerDidCancel:imagePicker]; expect(@(didSend)).to(beFalsy()); expect(@(didComplete)).to(beTruthy()); }); }); QuickSpecEnd ```
Arasvika or Arasvik is a village and ferry point in the municipality of Aure in Møre og Romsdal county, Norway. Name The oldest recorded form of the village's name is Oraldsuik, which appeared in a document from 1342. Geography Arasvika lies on the south side of the island of Ertvågsøy along Arasvik Fjord. There are road connections to Arasvika via County Road 682 from the north and County Road 362 from the east. The ferry connects the village to Hennset in the municipality of Halsa and European route E39. Notable people Notable people that were born or lived in Arasvika include: Holger Aresvik (1883–1938), fiddler and painter Oddvar Aresvik (1915–1996), professor of agricultural economics at the Norwegian College of Agriculture at Ås References External links Arasvika at Norgeskart Arasvika-Hennset ferry schedule Aure, Norway Villages in Møre og Romsdal
NCAA independent lacrosse schools are four-year institutions in the United States that do not belong to a lacrosse-only conference or a primary all-sports conference that sponsors lacrosse. As of the 2016–17 academic year there are 22 men's and 9 women's lacrosse programs in Division I, Division II, and Division III that compete as independents. Division I Men's The only team to play as an independent in the most recent 2023 season was Hartford, which began a transition from Division I to Division III in the 2021–22 school year. The 2022–23 school year, in which Hartford's entire athletic program (except men's and women's golf) was independent, was the last for Hartford in Division I, as it joined the D-III Commonwealth Coast Conference in July 2023. One school is a potential independent in the 2024 season. Le Moyne started a transition from Division II to Division I in July 2023 as the newest member of the Northeast Conference, which sponsors all of Le Moyne's current sports except men's lacrosse. Potential independent Women's Four schools competed as D-I independents in the 2023 season. As noted above, Hartford was a full independent in its final D-I season before moving to D-III in July 2023. San Diego State and UC Davis became independents after the 2021 season, when their former women's lacrosse home of the Mountain Pacific Sports Federation shut down its league due to a lack of sponsoring members. Both joined Pac-12 Conference women's lacrosse after the 2023 season. Xavier played its inaugural women's lacrosse season as an independent before starting play in its full-time home of the Big East Conference in 2024. No programs will compete as independents in the 2024 season. After the 2023 season, two programs that had been full members of conferences that sponsor women's lacrosse moved to conferences that do not sponsor the sport. Cincinnati left the American Athletic Conference for the Big 12 Conference, and Liberty left the ASUN Conference for Conference USA. Both schools kept their women's lacrosse programs in their former full-time conferences. Division II Women's Division III Men's Women's See also College lacrosse NCAA Independents References External links NCAA Lacrosse NCAA lists Indep NCAA independent schools
```php <?php declare(strict_types=1); namespace Psalm\Issue; class UnusedBaselineEntry extends ClassIssue { public const ERROR_LEVEL = -1; public const SHORTCODE = 316; } ```
John Henry Roraback (April 5, 1870 – May 19, 1937) was an American lawyer, businessman, and Republican political boss in the state of Connecticut. He was one of the most influential figures in early 20th century Connecticut, and had a national impact as well. Early life Roraback's father John C. Roraback was a farmer, the descendant of German immigrants from one of several settlements named "Rohrbach" in Lorraine who had settled in Columbia County, New York around 1700. He moved his family to Sheffield, Massachusetts in the Berkshires around 1846. Henry (as he seems to have been usually called) was born in 1870 in Sheffield, Massachusetts. He was educated in the local Sheffield schools and then attended high school in Great Barrington. At 19 he moved to North Canaan, Connecticut, where a number of his much older siblings were already established. Living with a sister there, he taught school nearby and studied law with his brother Alberto T. Roraback (1849-1923), a lawyer then serving as a county judge. He was admitted to the bar in 1892. He became a partner in his brother's prosperous practice. Political career Roraback became the chairman of the Republican Town Committee in Canaan and promoted his brother's successful candidacy for the state House of Representatives in 1895. In 1898 he was elected to the Republican State Committee. In 1900 he supported George P. McLean for governor over Donald T. Warner (son of his brother's old mentor Judge Donald J. Warner) and carried Warner's own district for McLean. In 1909 Roraback managed Ebenezer Hill's campaign for the US Senate and nearly unseated Frank Brandegee. In 1910 he managed McLean's successful campaign for the Senate. In 1912 he became Republican state party chairman - a post he retained until his death in 1937. Under Roraback's leadership the Republicans retained the governorship from 1915 to 1931. Roraback's fiscally conservative policies led to Connecticut paying down its state debt. Roraback was elected to the Republican National Committee in 1920, a position he also held until his death. In 1924 he served as the speaker of the Republican national convention and became a member of the executive committee. In 1932 he became one of the vice-chairmen. By that time Roraback was regarded as one of the "Old Guard" of the party, opposed to reform and strongly opposed to Roosevelt's New Deal. Business career Starting in 1901 Roraback represented the New York, New Haven and Hartford Railroad and was successful in protecting its interests. By 1905 Roraback had taken over and consolidated several small power companies serving Canaan and nearby areas into the Berkshire Power Company with himself as president. He obtained in 1905 a charter for the Rocky River Power Company to develop hydro power on the Housatonic River, rights which finally led to the organization of the Connecticut Light and Power Company in 1917 (with Roraback as president) and the construction of Candlewood Lake to store water and produce hydroelectric power in 1926–8. Roraback also served as president of a number of related power and utility concerns, and as a director of many Connecticut businesses. Around 1910 Roraback organized the New England Lime Company, a combination of a number of area lime kilns. Family and death Roraback married Mary L. Parsons on April 29, 1896. The couple had twins in 1899, but one child died an infant; his son Lewis survived and on his death in the early 1980s donated 1,976 acres of land in Harwinton to the state of Connecticut, now the Roraback Wildlife Management Area. Roraback also had an illegitimate son, John Anthony Craig, by his long-time personal assistant Mary Collins. The Depression caused the Republicans to lose power in Connecticut, and Roraback's control of the party came under increased scrutiny and criticism. A throat infection in 1936 left Roraback in poor health, and he committed suicide on May 19, 1937, shooting himself in the head after a morning hunt with his son. His obituary in Time magazine said, What Ohio's Marcus Alonzo ("Mark") Hanna did with the Republican Party nationally during the single Presidential generation of William McKinley, whipping Big Business to the Party treasury with fear of Bryan's silver money, cajoling it with protective tariffs and other favors, Boss Roraback did with controlled budgets, legislation favorable to industry, in Connecticut during eight gubernatorial terms. But public resentment against his dominance never rose very high because, though a monopolist, he was honest and not rapacious. His Yankee instinct was for payasyougo government and that is the kind New Englanders like. References 1870 births 1937 deaths People from Sheffield, Massachusetts Connecticut Republicans Connecticut lawyers American energy industry businesspeople American political bosses American people of German descent 1937 suicides Suicides by firearm in Connecticut
Mossman Shire Hall and Douglas Shire Council Chambers is a heritage-listed former town hall at 8-14 Mill Street, Mossman, Shire of Douglas, Queensland, Australia. It was designed by Hill & Taylor and built in 1937 by Tarmey & Euhus. It was added to the Queensland Heritage Register on 6 August 2010. History The former Mossman Shire Hall and Douglas Shire Council Chambers, constructed 1936–1937, is a substantial civic building that reflects the importance of the sugar industry to north Queensland during the interwar period and is associated with the ascendancy of Mossman as a commercial and administrative centre and the decline of Port Douglas as an early regional centre. The hall also demonstrates the pattern of construction of civic buildings for local government purposes during the 1930s using funds from the Queensland Government Unemployment Relief Scheme. The town of Mossman lies inland from Port Douglas, on the flood-plain of the Mossman River between the Great Dividing Range and the coast, about north of Cairns. Port Douglas was established in 1877 as an alternative to Cairns as a service port to the Hodgkinson goldfield, which had been proclaimed on 15 June 1876. With the construction of the Cairns-Kuranda railway line in 1882–1891, Port Douglas gradually declined as a town and port. The Mossman district, although initially taken up as homestead selections supplying fodder, maize and tropical fruits to the goldfields, converted to sugar-growing in the 1890s and prospered in the early twentieth century. During these formative years, the region was part of the Douglas Divisional Board (established in 1880) but was replaced by Douglas Shire Council on 30 March 1903 after the Local Authorities Act 1902 abolished divisional boards. The township of Mossman was created from a private subdivision made following the establishment of the Mossman Central Mill on the Mossman River in 1894-1895 under the Sugar Works Guarantee Act 1893. Sugar production in the Mossman district expanded rapidly from this time. Despite this, in 1910 the township comprised little more than the Exchange Hotel, a store, butcher's shop, hall and timber church, clustered around the sugar mill. These buildings and most of nearby Port Douglas were severely damaged by a cyclone on 16 March 1911. In the aftermath, and with the continued increase of both transient and permanent workers in the sugar industry, businesses at Port Douglas gradually gravitated to Mossman. In the 1920s the Court House and banking facilities moved from Port Douglas to Mossman, and by the end of the decade Mossman was the administrative centre of Douglas Shire. Despite the growing population in Mossman, Douglas Shire councillors continued to meet in Port Douglas. In 1932, however, the Queensland Government amended the Local Authorities Act so that governments-in-council could subdivide shires into divisions for election purposes. As a result, the Douglas Shire was divided into five divisions and all but one of the new divisions had one council member. Division three (Mossman River to South Mossman River) had two council members which gave residents of Mossman greater council representation and influence. A new council was elected in 1933 and Raymond David Rex was elected Chairman. Moves to improve town facilities began immediately, with the Mossman Chamber of Commerce requesting that Mossman be declared a municipality so that water services could be upgraded and street lights electrified. While Mossman never became a municipality, it did become the administrative and commercial hub of Douglas Shire, and from 1937, the seat of the Douglas Shire Council. In August 1934 Rex proposed council borrow and use subsidies from the Queensland Government's Unemployment Relief Scheme to build a new shire hall and council offices at Mossman on a site in the centre of the town, to which council had held the title since 1903. The Unemployment Relief Scheme was part of the Forgan Smith Labour Government's strategy to support employment. Many civic buildings and infrastructure projects were established across Queensland using this scheme, the Intermittent Relief Work Scheme, and projects managed by the Bureau of Industry. Other extant shire halls in Queensland that were constructed during this period include Gladstone Town Hall (1933-1934, now Gladstone Regional Art Gallery and Museum), Gayndah Soldier's Memorial Hall and Council Chambers (1935, now Gayndah Shire Hall), Bowen Shire Council Offices (1935-1937), Johnstone Shire Hall (1935-1938), and Goondiwindi Shire Hall (1937-1938, now the Goondiwindi Civic Centre). In Mossman, a special meeting was convened to discuss Rex's proposal. His vision to construct a hall, shire offices and commercial shops (to make the venture viable) was supported by other councillors and the proposal went to tender in October 1934. The council was split regarding the choice of design but eventually selected plans by well-known Cairns architects Richard Hill and AJH Taylor. Hill & Taylor, in partnership from 1927 to and then 1945 to 1952, designed a number of prominent north Queensland civic buildings between the first and second world wars, including the Cairns City Council Chambers (1929-1930), Cairns Post Office (1930), Johnstone Shire Hall in Innisfail (1935-1938) and a number of country hospitals, including Mossman District Hospital () and Proserpine Hospital (1939-1940). However, the process of finalising the design and layout was protracted. Continued deliberations regarding building components, style and plans caused delays and friction within the council, and between council and the architects. The final proposal stipulated that the new shire hall complex would comprise four commercial shops, council offices upstairs, a hall, supper lounge and ample stage accommodation. Costs were not to exceed . Three additional sets of plans were submitted before they were sent to the Public Works Department for approval. Its report outlined a range of issues that required attention and the architects were asked to amend plans and get their representative in Brisbane to liaise with them. Although tenders for the construction of the hall were called in July 1935 it was not until November 1935 that builders Arthur Zillfleisch and Tom Booth were nominated. Further problems saw the tender to build the hall eventually being awarded to Messrs Tarmey & Euhus, the firm that had submitted the lowest tender price of . Despite continued problems during the construction period, the building was finally completed in 1937 and officially opened on 9 June 1937. The new shire hall had four shops on the lower floor, including a chemist and cafe. The incorporation of retail spaces into public halls, theatres and large civic buildings was popular during the 1920s and 1930s - a means of maximising the income that could be derived from these large and expensive projects. The shire halls and council offices at Goondiwindi, Innisfail and Bowen, for example, all had ground floor, street-accessed retail spaces included as part of the design. If the building contained a public hall or theatre, one of the shops inevitably was occupied by a cafe. The Mossman Shire Hall, with its drop screen, stage and orchestra pit and dressing rooms, was subsequently used for a range of community events and functions. In 1938, alterations and additions were made by Hill & Taylor. These included: extending the awning to the pavement from the hall, a new area for storing chairs on the northern side of the building, new kitchen facilities in the commercial premises, and renewing flashing and box guttering on the southern side of building. During World War II, the hall was used by troops as a dance hall. In the 1970s, additions and alterations to the hall included enclosing the louvred wall on Mill Street with concrete block to reduce the noise from the tram line (which passes within two metres of the building) and to block out natural light. In 1996 Douglas Shire Council moved into new offices in Front Street, Mossman and vacated the offices on the upper level of the 1937 building. In 2008 Douglas Shire, Mulgrave Shire and City of Cairns were amalgamated under the Cairns Regional Council, with one representative from the former Douglas Shire. The former Mossman Shire Hall is still used for a variety of community events, while the commercial premises on the ground floor are occupied as shops or by community project groups. In June 2008 the entire former Douglas Shire was declared an iconic place under the Iconic Queensland Places Act 2008. In the gazetted declaration (No. 52, 20 June 2008) the built environment values listed as being notable and worthy of preservation include those related to Mossman being the administrative centre of the Shire. Description The former Mossman Shire Hall and Douglas Shire Council Chambers is a large rendered concrete building located on a level site in the centre of Mossman at the intersection of Mill Street (the main street of the town), Junction Road and the Captain Cook Highway. The building is orientated east–west extending along Mill Street. Its western end comprises two storeys with its principal south-west elevation truncated to face the intersection and giving it prominence as a civic building in the centre of the town. Retail premises (originally four shops) are located on the ground floor with offices (originally the council offices) on the first floor. The hall and its ancillary facilities including supper lounge, stage and fly tower occupy the remainder of the building and are located east of the shops along Mill Street. The shop fronts are protected by a cantilevered awning which has early pressed metal edge detailing; the westernmost shop has an entrance in the principal (south-west) elevation, and the remaining three shop fronts have entrances off MiIl Street. Three of the four shop fronts retain large metal framed display windows with recessed timber entrance doors and fixed panels (originally glazing) above. Walls surrounding the display windows have a dado of dark green glazed tiling decorated with geometric glazed tile patterns in pale green, red and black. The eastern shop front (to the former cafe) has been replaced with aluminium-framed glazing and entrance door and alternate tiling. Above the awning, the north-west, south-west and southern elevations to the offices have been articulated with classical detailing including pilasters and entablature. To the north-west and southern elevation the pilasters are paired with smaller pilasters of the Corinthian order. Eight multi-light steel-framed casement pairs with fanlights provide natural light and ventilation to the offices; one on the north-west elevation, three on the south-west elevation and four on the southern elevation. The gabled roof over the offices is concealed behind a parapet which steps up along the south-west elevation and to which three flagpoles are fixed. The cantilevered awning extends east over the entrance to the first floor offices, the entrance to the hall and the ticket office. A pair of three panelled timber doors provides access to the first floor offices and a roller door has replaced earlier entrance doors to the hall. The parapet above this section of the building is articulated with pilasters and a simple cornice and conceals a skillion roof to offices that are a later addition between the former council offices and hall. East of the hall foyer the building line steps back from the street alignment. The hall floor is approximately higher than street level and has two pairs of doors reached by pairs of stairs. The doors are set within concrete block walls which have replaced lower level banks of louvres that extended to the ceiling of the hall. This southern facade of the hall has a skillion-roofed verandah which is a later addition. The gabled roof to the hall is partially concealed behind a parapet along the southern elevation and has two clerestory lights along both sides. The walls to fly tower and southern dressing room are featureless apart from four small high level multi-light casements to the dressing room and a single window to the rear of the stage. The fly tower has a gabled roof, while the rear of the stage, a skillion roof. A parapet conceals a skillion roof over the dressing room. The eastern elevation of the building is largely featureless with three high level multi-light casements, a fourth casement at the back of the fly tower and a window to the rear of the dressing room. Three openings on the eastern elevation give access to the basement below the stage. The opening at the southern end has a pair of ledged doors, while the other two openings have been altered with infill panels and later doors. Adjacent to the north-east corner of the building is a small toilet block which is a later addition and partially conceals the early rear wall of the dressing room. The northern elevation of the supper lounge is clad in patterned board sheeting which appears to be a later addition. The kitchen adjacent to the supper lounge is clad in timber weatherboards. The northern elevation of the office and shop components has been substantially altered with concrete block additions. Commercial premises Interior partitions between the shops are of rendered concrete and the partition between the shops at the western end of the building has been removed, to form one larger retail space. Despite this change, the four former shop volumes are apparent and each retains early decorative cornices and ceiling roses. The third shop from the west was a former chemist and retains early timber cupboards and shelving. Alterations and additions have been made at the rear of the shops. First floor Chambers (former council offices) The stair hall leading to the first floor offices from Mill Street consists of 25 treads in a single flight with timber handrails fixed to the walls. The early office layout has been altered with additional partitions added and openings made in early walls. Some v-jointed tongue and groove partitions and early ceilings and geometric patterned cornices remain under later wall linings and above suspended ceilings. The timber cabinets at the enquiry counter appear to be early. The Hall The overall fabric of the hall is intact, although a few alterations have been made. The ceilings retain features such as decorative ceiling roses and cornices with geometric designs. The proscenium arch has elaborate mouldings with abstract geometric designs. Pairs of eight-light French doors opening to the north into the supper lounge are intact (although a few lights have been replaced), as is the timber floor. The walls at the rear of the hall are clad in later perforated acoustic corrugated steel sheets. The southern side of the hall has concrete block infill between structural concrete pillars with banks of louvres above the walls. Female toilets at the rear of the hall are an addition. The supper lounge and kitchen area retains its original form but appears to have no original features. Stage area The timber stage is approximately one metre above the hall floor. It has a raked floor and has been extended and possibly covers a former orchestra pit. The dressing rooms at either side of the stage have concrete walls, remain largely intact and follow the original plan. Steps lead down from this level to toilets which also can be accessed from the hall. One bathroom has been refitted. Underneath the stage are storage rooms accessed from outside. Heritage listing The former Mossman Shire Hall and Douglas Shire Council Chambers was listed on the Queensland Heritage Register on 6 August 2010 having satisfied the following criteria. The place is important in demonstrating the evolution or pattern of Queensland's history. The Mossman Shire Hall and Douglas Shire Council Chambers are important in demonstrating the pattern of Queensland's history, in particular the construction of civic buildings during the 1930s assisted by funding from relief and job-creation schemes. Civic projects - including shire and town halls, offices and chambers; community swimming pools; roads; bridges; and street and park beautification schemes - were undertaken throughout Queensland at this period as a result of these schemes, and as a group these places are important in articulating a particular historical period, the impact of State government initiatives to combat the economic depression, and design concepts popular at the time. The Mossman Shire Hall and Douglas Shire Council Chambers is a substantial building for a small administrative centre, and in this it is important in illustrating the era of prosperity accompanying the expansion of the north Queensland sugar industry during the 1920s and 1930s, and the shift during these years of the administrative heart of Douglas Shire from Port Douglas to Mossman in the State's northernmost sugar-growing district. The place is important in demonstrating the principal characteristics of a particular class of cultural places. The Mossman Shire Hall and Douglas Shire Council Chambers building is a good representative example of a regional civic complex. It remains substantially intact and is important in illustrating the principal characteristics of a 1930s civic building located in the centre of town on the corner of Mossman's principal streets, combining council offices and meeting rooms, retail spaces, and a large public hall with entry foyer, stage, fly-tower and dressing rooms. Early features include: steel-framed, multi-paned casement windows to the former offices; a cantilevered street awning with decorative metal edging; shop fronts with decorative ceramic tiles; timber cabinetry in the former chemist's shop; decorative plaster work to the ceilings of the former council offices; clerestory lights/ventilation panels in the roof of the hall; and timber floors throughout. The Mossman Shire Hall and Douglas Shire Council Chambers is significant as a building designed by the architectural partnership of Hill and Taylor, prominent local architects in north Queensland during the interwar period, and contributes to our understanding of their portfolio of work across this part of the state. References Attribution External links Queensland Heritage Register Mossman, Queensland Town halls in Queensland Articles incorporating text from the Queensland Heritage Register Buildings and structures in Far North Queensland
```smalltalk ///////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Tencent is pleased to support the open source community by making behaviac available. // // // // distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ///////////////////////////////////////////////////////////////////////////////////////////////////////////////// using System; using System.Collections.Generic; using System.Text; using System.IO; using Behaviac.Design; using Behaviac.Design.Attributes; namespace PluginBehaviac.DataExporters { public class StructCppExporter { public static void GenerateCode(object obj, DefaultObject defaultObj, StringWriter stream, string indent, string var, object parent, string paramName) { Debug.Check(obj != null); if (obj != null) { Type type = obj.GetType(); Debug.Check(Plugin.IsCustomClassType(type)); MethodDef method = parent as MethodDef; IList<DesignerPropertyInfo> properties = DesignerProperty.GetDesignerProperties(type); foreach (DesignerPropertyInfo property in properties) { if (!property.Attribute.HasFlags(DesignerProperty.DesignerFlags.NoSave)) { object member = property.GetValue(obj); Type memberType = member.GetType(); if (Plugin.IsArrayType(memberType)) { string memberNativeType = Plugin.GetNativeTypeName(memberType); string nativeTypeStr = DataCppExporter.GetGeneratedNativeType(memberNativeType); int startIndex = nativeTypeStr.IndexOf('<'); int endIndex = nativeTypeStr.LastIndexOf('>'); string itemType = nativeTypeStr.Substring(startIndex + 1, endIndex - startIndex - 1); ArrayCppExporter.GenerateCode(member, defaultObj, stream, indent, itemType, var + "." + property.Property.Name); } else { if (property.Attribute is DesignerStruct) { GenerateCode(member, defaultObj, stream, indent, var + "." + property.Property.Name, parent, paramName); } else { bool bStructProperty = false; if (method != null) { MethodDef.Param param = method.GetParam(paramName, property); if (param != null) { bStructProperty = true; ParameterCppExporter.GenerateCode(defaultObj, param, stream, indent, string.Empty, var + "." + property.Property.Name, string.Empty); } } if (!bStructProperty) { DataCppExporter.GenerateCode(member, defaultObj, stream, indent, string.Empty, var + "." + property.Property.Name, string.Empty); } } } } } } } public static void PostGenerateCode(object obj, StringWriter stream, string indent, string var, object parent, string paramName) { Debug.Check(obj != null); if (obj != null) { Type type = obj.GetType(); Debug.Check(Plugin.IsCustomClassType(type)); MethodDef method = parent as MethodDef; IList<DesignerPropertyInfo> properties = DesignerProperty.GetDesignerProperties(type); foreach (DesignerPropertyInfo property in properties) { if (!property.Attribute.HasFlags(DesignerProperty.DesignerFlags.NoSave)) { object member = property.GetValue(obj); if (property.Attribute is DesignerStruct) { PostGenerateCode(member, stream, indent, var + "." + property.Property.Name, parent, paramName); } else { if (method != null) { MethodDef.Param param = method.GetParam(paramName, property); if (param != null) { string nativeType = DataCppExporter.GetBasicGeneratedNativeType(param.NativeType); ParameterCppExporter.PostGenerateCode(param, stream, indent, nativeType, var + "." + property.Property.Name, string.Empty, method); } } } } } } } } } ```
Blood Warrior, known in Japan as , is a 1993 fighting arcade game developed by Atop and published by Kaneko. It is the successor to the 1992 fighting arcade game, Shogun Warriors, also developed by Atop and published by Kaneko. Unlike Shogun Warriors, Blood Warrior uses digitized images of real actors within the game instead of traditionally drawn sprites, and its addition of blood and gore draws similarities to Midway's Mortal Kombat franchise. Characters There are nine playable characters. Like its predecessor, the Japanese version contains original voice samples, while the North American and Worldwide versions were dubbed in English for some characters. - Based on Samurai from Shogun Warriors. - Based on Ninja from Shogun Warriors. - A ksitigarbha. - A kunoichi. - A kappa. , also known as Shigerutsuki - Resembles Shogun from Shogun Warriors, but his actual occupation is a samurai. - Based on Kabuki from Shogun Warriors. - Based on Saitō Musashibō Benkei, but has a different look compared to himself in Shogun Warriors. - Based on Ishikawa Goemon. Reception In Japan, Game Machine listed Blood Warrior on their September 1, 1994 issue as being the seventeenth most-successful table arcade unit of the month. See also The Kung-Fu Master Jackie Chan - another Mortal Kombat-inspired fighting arcade game released by Kaneko. References External links Blood Warrior at arcade-history 1993 video games Arcade video games Arcade-only video games Fighting games Kaneko games Mortal Kombat clones Multiplayer and single-player video games Video games about ninja Video games about samurai Video games developed in Japan Video games with digitized sprites
Goszczewo is a village in the administrative district of Gmina Srokowo, within Kętrzyn County, Warmian-Masurian Voivodeship, in northern Poland, close to the border with the Kaliningrad Oblast of Russia. The postal code of Goszczewo is 11-420. References Goszczewo
Abaqus FEA (formerly ABAQUS) is a software suite for finite element analysis and computer-aided engineering, originally released in 1978. The name and logo of this software are based on the abacus calculation tool. The Abaqus product suite consists of five core software products: Abaqus/CAE, or "Complete Abaqus Environment" (a backronym with a root in Computer-Aided Engineering). It is a software application used for both the modeling and analysis of mechanical components and assemblies (pre-processing) and visualizing the finite element analysis result. A subset of Abaqus/CAE including only the post-processing module can be launched independently in the Abaqus/Viewer product. Abaqus/Standard, a general-purpose Finite-Element analyzer that employs implicit integration scheme (traditional). Abaqus/Explicit, a special-purpose Finite-Element analyzer that employs explicit integration scheme to solve highly nonlinear systems with many complex contacts under transient loads. Abaqus/CFD, a Computational Fluid Dynamics software application which provides advanced computational fluid dynamics capabilities with extensive support for preprocessing and postprocessing provided in Abaqus/CAE - discontinued in Abaqus 2017 and further releases. Abaqus/Electromagnetic, a Computational electromagnetics software application which solves advanced computational electromagnetic problems. The Abaqus products use the open-source scripting language Python for scripting and customization. Abaqus/CAE uses the fox-toolkit for GUI development. History The name of Abaqus was initially written as ABAQUS when it was first released. The early history of ABAQUS is very tightly connected with the early history of MARC Analysis Research Corporation. Dr. David Hibbitt, Dr. Bengt Karlsson, and Dr. Paul Sorensen co-founded the company later known as Hibbitt, Karlsson & Sorensen, Inc., (HKS) in Jan, 1978 to develop and market ABAQUS software. Hibbitt and Sorensen had met while completing their Ph.Ds at Brown University while Karlsson encountered the two in his capacity as a support analyst in a data centre in Stockholm. The original logo of ABAQUS company is a stylized abacus calculator, and its beads are set to the company's official launch date of February 1, 1978 (2-1-1978). ABAQUS version 1 was created for a specific client -- Westinghouse Hanford Company which used the software to analyze nuclear fuel rod assemblies. ABAQUS version 3 was released in June 1979. In the early days, ABAQUS was designed primarily for the nonlinear static and dynamic analysis of structures, and nonlinear steady and transient analysis of heat transfer or conduction problems. It was initially distributed via CDC's Cybernet service. The first parallel version of ABAQUS, version 5.4, was made available to users in 1995. The core product, eventually known as ABAQUS/Standard which is an implicit finite element solver, was complemented by other software packages including ABAQUS/Explicit, a dynamic explicit analysis package released in 1992, and ABAQUS/CAE, a finite element pre- and post-processing package released in 1999. The first official release of ABAQUS/Explicit was hand-delivered to M.I.T. in 1992. Later on, the company's name was changed to ABAQUS, Inc. in late 2002 to reflect the company's focus on this product line. Then, in October 2005, the company with its 525 employees was acquired by Dassault Systèmes for $413 million or about four times the company's annual revenue of approximately $100 million. After that, ABAQUS, Inc. became part of Dassault Systèmes Simulia Corp. Dr. David Hibbitt was still with the company he co-founded as chairman while Mark Goldstein was president and CEO when the company was acquired by Dassault Systèmes. After 23 years of leadership, David Hibbitt retired in 2001; Bengt Karlsson and Paul Sorensen followed suit in the following year. All three are still living in New England. The headquarters of the company was located in Providence, Rhode Island until 2014. Since 2014, the headquarters of the company are located in Johnston, Rhode Island, United States. Release history The first version of ABAQUS was delivered/released in Sept. 1978. Version 3 of ABAQUS was released in June 1979. The first official release of ABAQUS/Explicit was in 1992. Version 0 of ABAQUS/Viewer was released as a standalone product in 1998. The same features were made available as the Visualization module of ABAQUS/CAE when it was first released in 1999. In recent years, a new version of Abaqus has been released near the end of every year. Applications Abaqus is used in the automotive, aerospace, and industrial products in industries. The product is popular with non-academic and research institutions in engineering due to the wide material modeling capability, and the program's ability to be customized, for example, users can define their own material models so that new materials could also be simulated in Abaqus. Abaqus also provides a good collection of multiphysics capabilities, such as coupled acoustic-structural, piezoelectric, and structural-pore capabilities, making it attractive for production-level simulations where multiple fields need to be coupled. Abaqus was initially designed to address non-linear physical behavior; as a result, the package has an extensive range of material models such as elastomeric (rubberlike) and hyperelastic (soft tissue) material capabilities. Here are some animated examples Solution Sequence Every complete finite-element analysis consists of 3 separate stages: Pre-processing or modeling: This stage involves creating an input file which contains an engineer's design for a finite-element analyzer (also called "solver"). Processing or finite element analysis: This stage produces an output visual file. Post-processing or generating report, image, animation, etc. from the output file: This stage is a visual rendering stage. Abaqus/CAE is capable of pre-processing, post-processing, and monitoring the processing stage of the solver; however, the first stage can also be done by other compatible CAD software, or even a text editor. Abaqus/Standard, Abaqus/Explicit or Abaqus/CFD are capable of accomplishing the processing stage. Dassault Systemes also produces Abaqus for CATIA for adding advanced processing and post processing stages to a pre-processor like CATIA. Solvers Comparison The following is a comparison between the solver capabilities of Abaqus/Standard and Abaqus/Explicit. Notes The more complex the contacts become, the more repetitive calculations ABAQUS/Standard has to solve, and the more time and disk space needed; ABAQUS Explicit is the optimal choice in this case Like static elements (see the picture,) dynamic elements, thermal elements and electrical elements Steady, Static and Constant loads are the same. Transient loads include: quasi-static loads (slowly varying loads in which the effect of inertial is small enough to neglect) and dynamic loads (faster varying loads). See also ABAQUS, Inc List of finite element software packages Dassault Systèmes References External links Dassault Systèmes Finite element software Finite element software for Linux 1978 software
Thelymitra cyanea, commonly known as the veined sun orchid in Australia and as the swamp sun orchid or striped sun orchid in New Zealand, is a species of orchid which is native to New Zealand and south-eastern Australia. It has a single erect, fleshy, channelled leaf and up to five bright blue flowers with darker blue veins. It is usually found growing in swamps, sphagnum bogs, and subalpine herbfields, often in clonal colonies. Description Thelymitra cyanea is a tuberous, perennial herb with a single erect, fleshy, channelled, linear leaf long and wide. Up to five bright blue flowers with darker veins, wide are borne on a flowering stem tall. There are usually and two bracts on the flowering stem. The sepals and petals are long and wide but the lavellum (the lowest petal) is larger than the other petals and sepals. The column is white to pale blue, long and about wide. The side arms of the column are yellow, with a twisted or toothed tip. The flowers are often self-pollinating and open on warm sunny days. Flowering occurs from November to March. Taxonomy and naming The veined sun orchid was first formally described in 1840 by John Lindley and given the name Macdonaldia cyanea. The description was published in his book A Sketch of the Vegetation of the Swan River Colony. In 1873 George Bentham changed the name to Thelymitra cyanea and published the change in Flora Australiensis. The specific epithet (cyanea) is derived from the Ancient Greek word kyanos meaning "dark blue". Distribution and habitat Thelymitra cyanea is widespread and often common in many parts of south-eastern Australia and New Zealand. It grows in damp to wet boggy places, mainly in montane and subalpine habitats. In New Zealand it is widespread on the North, South and Chatham Islands. In New South Wales it is found on the tablelands south from Ebor, in south-eastern Victoria and in Tasmania. In South Australia it is restricted to near Mount Compass. Conservation This orchid is widespread and common, but listed as "endangered" in South Australia where most of its former habitat has been drained and is now under cultivation. References External links cyanea Orchids of New South Wales Orchids of New Zealand Orchids of South Australia Orchids of Tasmania Orchids of the Australian Capital Territory Orchids of Victoria (state) Plants described in 1840
```c++ /* * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are * met: * * * Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * Redistributions in binary form must reproduce the above * copyright notice, this list of conditions and the following disclaimer * in the documentation and/or other materials provided with the * distribution. * * Neither the name of Google Inc. nor the names of its * contributors may be used to endorse or promote products derived from * this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #include "config.h" #include "web/WebViewImpl.h" #include "core/CSSValueKeywords.h" #include "core/HTMLNames.h" #include "core/InputTypeNames.h" #include "core/clipboard/DataObject.h" #include "core/dom/Document.h" #include "core/dom/DocumentMarkerController.h" #include "core/dom/Fullscreen.h" #include "core/dom/LayoutTreeBuilderTraversal.h" #include "core/dom/Text.h" #include "core/editing/Editor.h" #include "core/editing/FrameSelection.h" #include "core/editing/HTMLInterchange.h" #include "core/editing/InputMethodController.h" #include "core/editing/iterators/TextIterator.h" #include "core/editing/markup.h" #include "core/events/KeyboardEvent.h" #include "core/events/UIEventWithKeyState.h" #include "core/events/WheelEvent.h" #include "core/fetch/UniqueIdentifier.h" #include "core/frame/EventHandlerRegistry.h" #include "core/frame/FrameHost.h" #include "core/frame/FrameView.h" #include "core/frame/LocalFrame.h" #include "core/frame/PageScaleConstraintsSet.h" #include "core/frame/PinchViewport.h" #include "core/frame/RemoteFrame.h" #include "core/frame/Settings.h" #include "core/frame/SmartClip.h" #include "core/frame/TopControls.h" #include "core/html/HTMLInputElement.h" #include "core/html/HTMLMediaElement.h" #include "core/html/HTMLPlugInElement.h" #include "core/html/HTMLTextAreaElement.h" #include "core/html/forms/PopupMenuClient.h" #include "core/input/EventHandler.h" #include "core/layout/LayoutPart.h" #include "core/layout/LayoutView.h" #include "core/layout/TextAutosizer.h" #include "core/layout/compositing/DeprecatedPaintLayerCompositor.h" #include "core/loader/DocumentLoader.h" #include "core/loader/FrameLoadRequest.h" #include "core/loader/FrameLoader.h" #include "core/page/ContextMenuController.h" #include "core/page/ContextMenuProvider.h" #include "core/page/DragController.h" #include "core/page/DragData.h" #include "core/page/DragSession.h" #include "core/page/FocusController.h" #include "core/page/FrameTree.h" #include "core/page/Page.h" #include "core/page/PagePopupClient.h" #include "core/page/PointerLockController.h" #include "core/page/ScopedPageLoadDeferrer.h" #include "core/page/TouchDisambiguation.h" #include "core/paint/DeprecatedPaintLayer.h" #include "core/timing/DOMWindowPerformance.h" #include "core/timing/Performance.h" #include "modules/accessibility/AXObject.h" #include "modules/accessibility/AXObjectCacheImpl.h" #include "modules/credentialmanager/CredentialManagerClient.h" #include "modules/encryptedmedia/MediaKeysController.h" #include "modules/storage/StorageNamespaceController.h" #if 1 // def MINIBLINK_NOT_IMPLEMENTED #include "modules/webgl/WebGLRenderingContext.h" #endif // MINIBLINK_NOT_IMPLEMENTED #include "platform/ContextMenu.h" #include "platform/ContextMenuItem.h" #include "platform/Cursor.h" #include "platform/KeyboardCodes.h" #include "platform/Logging.h" #include "platform/NotImplemented.h" #include "platform/PlatformGestureEvent.h" #include "platform/PlatformKeyboardEvent.h" #include "platform/PlatformMouseEvent.h" #include "platform/PlatformWheelEvent.h" #include "platform/RuntimeEnabledFeatures.h" #include "platform/TraceEvent.h" #include "platform/UserGestureIndicator.h" #include "platform/exported/WebActiveGestureAnimation.h" #include "platform/fonts/FontCache.h" #include "platform/graphics/Color.h" #include "platform/graphics/FirstPaintInvalidationTracking.h" #include "platform/graphics/Image.h" #include "platform/graphics/ImageBuffer.h" #include "platform/graphics/gpu/DrawingBuffer.h" #include "platform/scroll/ScrollbarTheme.h" #include "platform/weborigin/SchemeRegistry.h" #include "public/platform/Platform.h" #include "public/platform/WebCompositeAndReadbackAsyncCallback.h" #include "public/platform/WebDragData.h" #include "public/platform/WebFloatPoint.h" #include "public/platform/WebGestureCurve.h" #include "public/platform/WebImage.h" #include "public/platform/WebLayerTreeView.h" #include "public/platform/WebURLRequest.h" #include "public/platform/WebVector.h" #include "public/web/WebAXObject.h" #include "public/web/WebActiveWheelFlingParameters.h" #include "public/web/WebAutofillClient.h" #include "public/web/WebBeginFrameArgs.h" #include "public/web/WebElement.h" #include "public/web/WebFrame.h" #include "public/web/WebFrameClient.h" #include "public/web/WebHitTestResult.h" #include "public/web/WebInputElement.h" #include "public/web/WebMediaPlayerAction.h" #include "public/web/WebNode.h" #include "public/web/WebPlugin.h" #include "public/web/WebPluginAction.h" #include "public/web/WebRange.h" #include "public/web/WebSelection.h" #include "public/web/WebTextInputInfo.h" #include "public/web/WebViewClient.h" #include "public/web/WebWindowFeatures.h" #include "web/CompositionUnderlineVectorBuilder.h" #include "web/ContextFeaturesClientImpl.h" #include "web/DatabaseClientImpl.h" #include "web/DevToolsEmulator.h" #include "web/FullscreenController.h" #include "web/GraphicsLayerFactoryChromium.h" #include "web/InspectorOverlayImpl.h" #include "web/LinkHighlight.h" #include "web/PrerendererClientImpl.h" #include "web/ResizeViewportAnchor.h" #include "web/RotationViewportAnchor.h" #include "web/SpeechRecognitionClientProxy.h" #include "web/StorageQuotaClientImpl.h" #include "web/ValidationMessageClientImpl.h" #include "web/ViewportAnchor.h" #include "web/WebDevToolsAgentImpl.h" #include "web/WebInputEventConversion.h" #include "web/WebLocalFrameImpl.h" #include "web/WebPagePopupImpl.h" #include "web/WebPluginContainerImpl.h" #include "web/WebRemoteFrameImpl.h" #include "web/WebSettingsImpl.h" #include "web/WorkerGlobalScopeProxyProviderImpl.h" #include "web/painting/ContinuousPainter.h" #include "wtf/CurrentTime.h" #include "wtf/RefPtr.h" #include "wtf/TemporaryChange.h" #if USE(DEFAULT_RENDER_THEME) #include "core/layout/LayoutThemeDefault.h" #endif // Get rid of WTF's pow define so we can use std::pow. #undef pow #include <cmath> // for std::pow // The following constants control parameters for automated scaling of webpages // (such as due to a double tap gesture or find in page etc.). These are // experimentally determined. static const int touchPointPadding = 32; static const int nonUserInitiatedPointPadding = 11; static const float minScaleDifference = 0.01f; static const float doubleTapZoomContentDefaultMargin = 5; static const float doubleTapZoomContentMinimumMargin = 2; static const double doubleTapZoomAnimationDurationInSeconds = 0.25; static const float doubleTapZoomAlreadyLegibleRatio = 1.2f; static const double multipleTargetsZoomAnimationDurationInSeconds = 0.25; static const double findInPageAnimationDurationInSeconds = 0; // Constants for viewport anchoring on resize. static const float viewportAnchorCoordX = 0.5f; static const float viewportAnchorCoordY = 0; // Constants for zooming in on a focused text field. static const double scrollAndScaleAnimationDurationInSeconds = 0.2; static const int minReadableCaretHeight = 16; static const int minReadableCaretHeightForTextArea = 13; static const float minScaleChangeToTriggerZoom = 1.5f; static const float leftBoxRatio = 0.3f; static const int caretPadding = 10; namespace blink { // Change the text zoom level by kTextSizeMultiplierRatio each time the user // zooms text in or out (ie., change by 20%). The min and max values limit // text zoom to half and 3x the original text size. These three values match // those in Apple's port in WebKit/WebKit/WebView/WebView.mm const double WebView::textSizeMultiplierRatio = 1.2; const double WebView::minTextSizeMultiplier = 0.5; const double WebView::maxTextSizeMultiplier = 3.0; // Used to defer all page activity in cases where the embedder wishes to run // a nested event loop. Using a stack enables nesting of message loop invocations. static WillBeHeapVector<RawPtrWillBeMember<ScopedPageLoadDeferrer>>& pageLoadDeferrerStack() { DEFINE_STATIC_LOCAL(OwnPtrWillBePersistent<WillBeHeapVector<RawPtrWillBeMember<ScopedPageLoadDeferrer>>>, deferrerStack, (adoptPtrWillBeNoop(new WillBeHeapVector<RawPtrWillBeMember<ScopedPageLoadDeferrer>>()))); return *deferrerStack; } // Ensure that the WebDragOperation enum values stay in sync with the original // DragOperation constants. #define STATIC_ASSERT_MATCHING_ENUM(coreName) \ static_assert(int(coreName) == int(Web##coreName), "DragOperation and WebDragOperation enum mismatch: " #coreName) STATIC_ASSERT_MATCHING_ENUM(DragOperationNone); STATIC_ASSERT_MATCHING_ENUM(DragOperationCopy); STATIC_ASSERT_MATCHING_ENUM(DragOperationLink); STATIC_ASSERT_MATCHING_ENUM(DragOperationGeneric); STATIC_ASSERT_MATCHING_ENUM(DragOperationPrivate); STATIC_ASSERT_MATCHING_ENUM(DragOperationMove); STATIC_ASSERT_MATCHING_ENUM(DragOperationDelete); STATIC_ASSERT_MATCHING_ENUM(DragOperationEvery); static bool shouldUseExternalPopupMenus = false; namespace { class UserGestureNotifier { public: // If a UserGestureIndicator is created for a user gesture since the last // page load and *userGestureObserved is false, the UserGestureNotifier // will notify the client and set *userGestureObserved to true. UserGestureNotifier(WebAutofillClient*, bool* userGestureObserved); ~UserGestureNotifier(); private: WebAutofillClient* const m_client; bool* const m_userGestureObserved; }; UserGestureNotifier::UserGestureNotifier(WebAutofillClient* client, bool* userGestureObserved) : m_client(client) , m_userGestureObserved(userGestureObserved) { ASSERT(m_userGestureObserved); } UserGestureNotifier::~UserGestureNotifier() { if (!*m_userGestureObserved && UserGestureIndicator::processedUserGestureSinceLoad()) { *m_userGestureObserved = true; if (m_client) m_client->firstUserGestureObserved(); } } class EmptyEventListener final : public EventListener { public: static PassRefPtr<EmptyEventListener> create() { return adoptRef(new EmptyEventListener()); } bool operator==(const EventListener& other) override { return this == &other; } private: EmptyEventListener() : EventListener(CPPEventListenerType) { } void handleEvent(ExecutionContext* executionContext, Event*) override { } }; } // namespace // WebView your_sha256_hash WebView* WebView::create(WebViewClient* client) { // Pass the WebViewImpl's self-reference to the caller. return WebViewImpl::create(client); } WebViewImpl* WebViewImpl::create(WebViewClient* client) { // Pass the WebViewImpl's self-reference to the caller. return adoptRef(new WebViewImpl(client)).leakRef(); } void WebView::setUseExternalPopupMenus(bool useExternalPopupMenus) { shouldUseExternalPopupMenus = useExternalPopupMenus; } void WebView::updateVisitedLinkState(unsigned long long linkHash) { Page::visitedStateChanged(linkHash); } void WebView::resetVisitedLinkState() { Page::allVisitedStateChanged(); } void WebView::willEnterModalLoop() { pageLoadDeferrerStack().append(new ScopedPageLoadDeferrer()); } void WebView::didExitModalLoop() { ASSERT(pageLoadDeferrerStack().size()); ScopedPageLoadDeferrer* deferrer = pageLoadDeferrerStack().last(); #if ENABLE(OILPAN) deferrer->dispose(); #else delete deferrer; #endif pageLoadDeferrerStack().removeLast(); } void WebViewImpl::setMainFrame(WebFrame* frame) { if (frame->isWebLocalFrame()) { WebLocalFrameImpl* localFrame = toWebLocalFrameImpl(frame); localFrame->initializeCoreFrame(&page()->frameHost(), 0, nullAtom, nullAtom); // Composited WebViews want repaints outside the frame visible rect. localFrame->frame()->view()->setClipsRepaints(!m_layerTreeView); } else { toWebRemoteFrameImpl(frame)->initializeCoreFrame(&page()->frameHost(), 0, nullAtom); } } void WebViewImpl::setCredentialManagerClient(WebCredentialManagerClient* webCredentialManagerClient) { #ifdef MINIBLINK_NOT_IMPLEMENTED ASSERT(m_page); provideCredentialManagerClientTo(*m_page, new CredentialManagerClient(webCredentialManagerClient)); #endif // MINIBLINK_NOT_IMPLEMENTED notImplemented(); } void WebViewImpl::setPrerendererClient(WebPrerendererClient* prerendererClient) { #ifdef MINIBLINK_NOT_IMPLEMENTED ASSERT(m_page); providePrerendererClientTo(*m_page, new PrerendererClientImpl(prerendererClient)); #endif // MINIBLINK_NOT_IMPLEMENTED notImplemented(); } void WebViewImpl::setSpellCheckClient(WebSpellCheckClient* spellCheckClient) { m_spellCheckClient = spellCheckClient; } // static HashSet<WebViewImpl*>& WebViewImpl::allInstances() { DEFINE_STATIC_LOCAL(HashSet<WebViewImpl*>, allInstances, ()); return allInstances; } WebViewImpl::WebViewImpl(WebViewClient* client) : m_client(client) , m_spellCheckClient(0) , m_chromeClientImpl(this) , m_contextMenuClientImpl(this) , m_dragClientImpl(this) , m_editorClientImpl(this) , m_spellCheckerClientImpl(this) , m_storageClientImpl(this) , m_shouldAutoResize(false) , m_zoomLevel(0) , m_minimumZoomLevel(zoomFactorToZoomLevel(minTextSizeMultiplier)) , m_maximumZoomLevel(zoomFactorToZoomLevel(maxTextSizeMultiplier)) , m_maximumLegibleScale(1) , m_doubleTapZoomPageScaleFactor(0) , m_doubleTapZoomPending(false) , m_enableFakePageScaleAnimationForTesting(false) , m_fakePageScaleAnimationPageScaleFactor(0) , m_fakePageScaleAnimationUseAnchor(false) , m_contextMenuAllowed(false) , m_doingDragAndDrop(false) , m_ignoreInputEvents(false) , m_compositorDeviceScaleFactorOverride(0) , m_rootLayerScale(1) , m_suppressNextKeypressEvent(false) , m_imeAcceptEvents(true) , m_operationsAllowed(WebDragOperationNone) , m_dragOperation(WebDragOperationNone) , m_devToolsEmulator(nullptr) , m_isTransparent(false) , m_tabsToLinks(false) , m_layerTreeView(0) , m_rootLayer(0) , m_rootGraphicsLayer(0) , m_rootTransformLayer(0) , m_graphicsLayerFactory(adoptPtr(new GraphicsLayerFactoryChromium(this))) , m_matchesHeuristicsForGpuRasterization(false) , m_recreatingGraphicsContext(false) , m_flingModifier(0) , m_flingSourceDevice(false) , m_fullscreenController(FullscreenController::create(this)) , m_showFPSCounter(false) , m_continuousPaintingEnabled(false) , m_baseBackgroundColor(Color::white) , m_backgroundColorOverride(Color::transparent) , m_zoomFactorOverride(0) , m_userGestureObserved(false) , m_displayMode(WebDisplayModeBrowser) , m_elasticOverscroll(FloatSize()) { Page::PageClients pageClients; pageClients.chromeClient = &m_chromeClientImpl; pageClients.contextMenuClient = &m_contextMenuClientImpl; pageClients.editorClient = &m_editorClientImpl; pageClients.dragClient = &m_dragClientImpl; pageClients.spellCheckerClient = &m_spellCheckerClientImpl; m_page = adoptPtrWillBeNoop(new Page(pageClients)); #ifdef MINIBLINK_NOT_IMPLEMENTED MediaKeysController::provideMediaKeysTo(*m_page, &m_mediaKeysClientImpl); provideSpeechRecognitionTo(*m_page, SpeechRecognitionClientProxy::create(client ? client->speechRecognizer() : 0)); provideDatabaseClientTo(*m_page, DatabaseClientImpl::create()); #endif // MINIBLINK_NOT_IMPLEMENTED provideWorkerGlobalScopeProxyProviderTo(*m_page, WorkerGlobalScopeProxyProviderImpl::create()); provideContextFeaturesTo(*m_page, ContextFeaturesClientImpl::create()); provideStorageQuotaClientTo(*m_page, StorageQuotaClientImpl::create()); StorageNamespaceController::provideStorageNamespaceTo(*m_page, &m_storageClientImpl); m_page->setValidationMessageClient(ValidationMessageClientImpl::create(*this)); m_page->makeOrdinary(); if (m_client) { setDeviceScaleFactor(m_client->screenInfo().deviceScaleFactor); setVisibilityState(m_client->visibilityState(), true); } initializeLayerTreeView(); m_devToolsEmulator = adoptPtr(new DevToolsEmulator(this)); allInstances().add(this); } WebViewImpl::~WebViewImpl() { ASSERT(!m_page); } WebDevToolsAgentImpl* WebViewImpl::mainFrameDevToolsAgentImpl() { WebLocalFrameImpl* mainFrame = mainFrameImpl(); return mainFrame ? mainFrame->devToolsAgentImpl() : nullptr; } InspectorOverlay* WebViewImpl::inspectorOverlay() { if (!m_inspectorOverlay) m_inspectorOverlay = InspectorOverlayImpl::create(this); return m_inspectorOverlay.get(); } WebLocalFrameImpl* WebViewImpl::mainFrameImpl() { return m_page && m_page->mainFrame() && m_page->mainFrame()->isLocalFrame() ? WebLocalFrameImpl::fromFrame(m_page->deprecatedLocalMainFrame()) : 0; } bool WebViewImpl::tabKeyCyclesThroughElements() const { ASSERT(m_page); return m_page->tabKeyCyclesThroughElements(); } void WebViewImpl::setTabKeyCyclesThroughElements(bool value) { if (m_page) m_page->setTabKeyCyclesThroughElements(value); } void WebViewImpl::handleMouseLeave(LocalFrame& mainFrame, const WebMouseEvent& event) { m_client->setMouseOverURL(WebURL()); PageWidgetEventHandler::handleMouseLeave(mainFrame, event); } void WebViewImpl::handleMouseDown(LocalFrame& mainFrame, const WebMouseEvent& event) { // If there is a popup open, close it as the user is clicking on the page // (outside of the popup). We also save it so we can prevent a click on an // element from immediately reopening the same popup. RefPtr<WebPagePopupImpl> pagePopup; if (event.button == WebMouseEvent::ButtonLeft) { pagePopup = m_pagePopup; hidePopups(); ASSERT(!m_pagePopup); } m_lastMouseDownPoint = WebPoint(event.x, event.y); // Take capture on a mouse down on a plugin so we can send it mouse events. // If the hit node is a plugin but a scrollbar is over it don't start mouse // capture because it will interfere with the scrollbar receiving events. IntPoint point(event.x, event.y); if (event.button == WebMouseEvent::ButtonLeft && m_page->mainFrame()->isLocalFrame()) { point = m_page->deprecatedLocalMainFrame()->view()->rootFrameToContents(point); HitTestResult result(m_page->deprecatedLocalMainFrame()->eventHandler().hitTestResultAtPoint(point)); result.setToShadowHostIfInUserAgentShadowRoot(); Node* hitNode = result.innerNodeOrImageMapImage(); if (!result.scrollbar() && hitNode && hitNode->layoutObject() && hitNode->layoutObject()->isEmbeddedObject()) { m_mouseCaptureNode = hitNode; TRACE_EVENT_ASYNC_BEGIN0("input", "capturing mouse", this); } } PageWidgetEventHandler::handleMouseDown(mainFrame, event); if (event.button == WebMouseEvent::ButtonLeft && m_mouseCaptureNode) m_mouseCaptureGestureToken = mainFrame.eventHandler().takeLastMouseDownGestureToken(); if (m_pagePopup && pagePopup && m_pagePopup->hasSamePopupClient(pagePopup.get())) { // That click triggered a page popup that is the same as the one we just closed. // It needs to be closed. cancelPagePopup(); } // Dispatch the contextmenu event regardless of if the click was swallowed. if (!page()->settings().showContextMenuOnMouseUp()) { #if OS(MACOSX) if (event.button == WebMouseEvent::ButtonRight || (event.button == WebMouseEvent::ButtonLeft && event.modifiers & WebMouseEvent::ControlKey)) mouseContextMenu(event); #else if (event.button == WebMouseEvent::ButtonRight) mouseContextMenu(event); #endif } } void WebViewImpl::setDisplayMode(WebDisplayMode mode) { m_displayMode = mode; if (!mainFrameImpl() || !mainFrameImpl()->frameView()) return; mainFrameImpl()->frameView()->setDisplayMode(mode); } void WebViewImpl::mouseContextMenu(const WebMouseEvent& event) { if (!mainFrameImpl() || !mainFrameImpl()->frameView()) return; m_page->contextMenuController().clearContextMenu(); PlatformMouseEventBuilder pme(mainFrameImpl()->frameView(), event); // Find the right target frame. See issue 1186900. HitTestResult result = hitTestResultForRootFramePos(pme.position()); Frame* targetFrame; if (result.innerNodeOrImageMapImage()) targetFrame = result.innerNodeOrImageMapImage()->document().frame(); else targetFrame = m_page->focusController().focusedOrMainFrame(); if (!targetFrame->isLocalFrame()) return; LocalFrame* targetLocalFrame = toLocalFrame(targetFrame); #if OS(WIN) targetLocalFrame->view()->setCursor(pointerCursor()); #endif m_contextMenuAllowed = true; targetLocalFrame->eventHandler().sendContextMenuEvent(pme, nullptr); m_contextMenuAllowed = false; // Actually showing the context menu is handled by the ContextMenuClient // implementation... } void WebViewImpl::handleMouseUp(LocalFrame& mainFrame, const WebMouseEvent& event) { PageWidgetEventHandler::handleMouseUp(mainFrame, event); if (page()->settings().showContextMenuOnMouseUp()) { // Dispatch the contextmenu event regardless of if the click was swallowed. // On Mac/Linux, we handle it on mouse down, not up. if (event.button == WebMouseEvent::ButtonRight) mouseContextMenu(event); } } bool WebViewImpl::handleMouseWheel(LocalFrame& mainFrame, const WebMouseWheelEvent& event) { hidePopups(); return PageWidgetEventHandler::handleMouseWheel(mainFrame, event); } bool WebViewImpl::scrollBy(const WebFloatSize& delta, const WebFloatSize& velocity) { if (m_flingSourceDevice == WebGestureDeviceTouchpad) { WebMouseWheelEvent syntheticWheel; const float tickDivisor = WheelEvent::TickMultiplier; syntheticWheel.deltaX = delta.width; syntheticWheel.deltaY = delta.height; syntheticWheel.wheelTicksX = delta.width / tickDivisor; syntheticWheel.wheelTicksY = delta.height / tickDivisor; syntheticWheel.hasPreciseScrollingDeltas = true; syntheticWheel.x = m_positionOnFlingStart.x; syntheticWheel.y = m_positionOnFlingStart.y; syntheticWheel.globalX = m_globalPositionOnFlingStart.x; syntheticWheel.globalY = m_globalPositionOnFlingStart.y; syntheticWheel.modifiers = m_flingModifier; if (m_page && m_page->mainFrame() && m_page->mainFrame()->isLocalFrame() && m_page->deprecatedLocalMainFrame()->view()) return handleMouseWheel(*m_page->deprecatedLocalMainFrame(), syntheticWheel); } else { WebGestureEvent syntheticGestureEvent; syntheticGestureEvent.type = WebInputEvent::GestureScrollUpdate; syntheticGestureEvent.data.scrollUpdate.preventPropagation = true; syntheticGestureEvent.data.scrollUpdate.deltaX = delta.width; syntheticGestureEvent.data.scrollUpdate.deltaY = delta.height; syntheticGestureEvent.data.scrollUpdate.velocityX = velocity.width; syntheticGestureEvent.data.scrollUpdate.velocityY = velocity.height; syntheticGestureEvent.x = m_positionOnFlingStart.x; syntheticGestureEvent.y = m_positionOnFlingStart.y; syntheticGestureEvent.globalX = m_globalPositionOnFlingStart.x; syntheticGestureEvent.globalY = m_globalPositionOnFlingStart.y; syntheticGestureEvent.modifiers = m_flingModifier; syntheticGestureEvent.sourceDevice = WebGestureDeviceTouchscreen; syntheticGestureEvent.data.scrollUpdate.inertial = true; if (m_page && m_page->mainFrame() && m_page->mainFrame()->isLocalFrame() && m_page->deprecatedLocalMainFrame()->view()) return handleGestureEvent(syntheticGestureEvent); } return false; } bool WebViewImpl::handleGestureEvent(const WebGestureEvent& event) { if (!m_client) return false; bool eventSwallowed = false; bool eventCancelled = false; // for disambiguation // Special handling for slow-path fling gestures. switch (event.type) { case WebInputEvent::GestureFlingStart: { if (mainFrameImpl()->frame()->eventHandler().isScrollbarHandlingGestures()) break; endActiveFlingAnimation(); m_client->cancelScheduledContentIntents(); m_positionOnFlingStart = WebPoint(event.x, event.y); m_globalPositionOnFlingStart = WebPoint(event.globalX, event.globalY); m_flingModifier = event.modifiers; m_flingSourceDevice = event.sourceDevice; OwnPtr<WebGestureCurve> flingCurve = adoptPtr(Platform::current()->createFlingAnimationCurve(event.sourceDevice, WebFloatPoint(event.data.flingStart.velocityX, event.data.flingStart.velocityY), WebSize())); ASSERT(flingCurve); m_gestureAnimation = WebActiveGestureAnimation::createAtAnimationStart(flingCurve.release(), this); scheduleAnimation(); eventSwallowed = true; m_client->didHandleGestureEvent(event, eventCancelled); return eventSwallowed; } case WebInputEvent::GestureFlingCancel: if (endActiveFlingAnimation()) eventSwallowed = true; m_client->didHandleGestureEvent(event, eventCancelled); return eventSwallowed; default: break; } PlatformGestureEventBuilder platformEvent(mainFrameImpl()->frameView(), event); // Special handling for double tap and scroll events as we don't want to // hit test for them. switch (event.type) { case WebInputEvent::GestureDoubleTap: if (m_webSettings->doubleTapToZoomEnabled() && minimumPageScaleFactor() != maximumPageScaleFactor()) { m_client->cancelScheduledContentIntents(); animateDoubleTapZoom(platformEvent.position()); } // GestureDoubleTap is currently only used by Android for zooming. For WebCore, // GestureTap with tap count = 2 is used instead. So we drop GestureDoubleTap here. eventSwallowed = true; m_client->didHandleGestureEvent(event, eventCancelled); return eventSwallowed; case WebInputEvent::GestureScrollBegin: m_client->cancelScheduledContentIntents(); case WebInputEvent::GestureScrollEnd: case WebInputEvent::GestureScrollUpdate: case WebInputEvent::GestureFlingStart: // Scrolling-related gesture events invoke EventHandler recursively for each frame down // the chain, doing a single-frame hit-test per frame. This matches handleWheelEvent. // Perhaps we could simplify things by rewriting scroll handling to work inner frame // out, and then unify with other gesture events. eventSwallowed = mainFrameImpl()->frame()->eventHandler().handleGestureScrollEvent(platformEvent); m_client->didHandleGestureEvent(event, eventCancelled); return eventSwallowed; case WebInputEvent::GesturePinchBegin: case WebInputEvent::GesturePinchEnd: case WebInputEvent::GesturePinchUpdate: return false; default: break; } // Hit test across all frames and do touch adjustment as necessary for the event type. GestureEventWithHitTestResults targetedEvent = m_page->deprecatedLocalMainFrame()->eventHandler().targetGestureEvent(platformEvent); // Handle link highlighting outside the main switch to avoid getting lost in the // complicated set of cases handled below. switch (event.type) { case WebInputEvent::GestureShowPress: // Queue a highlight animation, then hand off to regular handler. enableTapHighlightAtPoint(targetedEvent); break; case WebInputEvent::GestureTapCancel: case WebInputEvent::GestureTap: case WebInputEvent::GestureLongPress: for (size_t i = 0; i < m_linkHighlights.size(); ++i) m_linkHighlights[i]->startHighlightAnimationIfNeeded(); break; default: break; } switch (event.type) { case WebInputEvent::GestureTap: { m_client->cancelScheduledContentIntents(); if (detectContentOnTouch(targetedEvent)) { eventSwallowed = true; break; } // Don't trigger a disambiguation popup on sites designed for mobile devices. // Instead, assume that the page has been designed with big enough buttons and links. // Don't trigger a disambiguation popup when screencasting, since it's implemented outside of // compositor pipeline and is not being screencasted itself. This leads to bad user experience. WebDevToolsAgentImpl* devTools = mainFrameDevToolsAgentImpl(); bool screencastEnabled = devTools && devTools->screencastEnabled(); if (event.data.tap.width > 0 && !shouldDisableDesktopWorkarounds() && !screencastEnabled) { IntRect boundingBox(page()->frameHost().pinchViewport().viewportToRootFrame(IntRect( event.x - event.data.tap.width / 2, event.y - event.data.tap.height / 2, event.data.tap.width, event.data.tap.height))); // FIXME: We shouldn't pass details of the PinchViewport offset to render_view_impl. WebSize pinchViewportOffset = flooredIntSize(page()->frameHost().pinchViewport().location()); if (m_webSettings->multiTargetTapNotificationEnabled()) { Vector<IntRect> goodTargets; WillBeHeapVector<RawPtrWillBeMember<Node>> highlightNodes; findGoodTouchTargets(boundingBox, mainFrameImpl()->frame(), goodTargets, highlightNodes); // FIXME: replace touch adjustment code when numberOfGoodTargets == 1? // Single candidate case is currently handled by: path_to_url if (goodTargets.size() >= 2 && m_client && m_client->didTapMultipleTargets(pinchViewportOffset, boundingBox, goodTargets)) { enableTapHighlights(highlightNodes); for (size_t i = 0; i < m_linkHighlights.size(); ++i) m_linkHighlights[i]->startHighlightAnimationIfNeeded(); eventSwallowed = true; eventCancelled = true; break; } } } eventSwallowed = mainFrameImpl()->frame()->eventHandler().handleGestureEvent(targetedEvent); break; } case WebInputEvent::GestureTwoFingerTap: case WebInputEvent::GestureLongPress: case WebInputEvent::GestureLongTap: { if (!mainFrameImpl() || !mainFrameImpl()->frameView()) break; m_client->cancelScheduledContentIntents(); m_page->contextMenuController().clearContextMenu(); m_contextMenuAllowed = true; eventSwallowed = mainFrameImpl()->frame()->eventHandler().handleGestureEvent(targetedEvent); m_contextMenuAllowed = false; break; } case WebInputEvent::GestureShowPress: m_client->cancelScheduledContentIntents(); case WebInputEvent::GestureTapDown: case WebInputEvent::GestureTapCancel: case WebInputEvent::GestureTapUnconfirmed: { eventSwallowed = mainFrameImpl()->frame()->eventHandler().handleGestureEvent(targetedEvent); break; } default: ASSERT_NOT_REACHED(); } m_client->didHandleGestureEvent(event, eventCancelled); return eventSwallowed; } bool WebViewImpl::handleSyntheticWheelFromTouchpadPinchEvent(const WebGestureEvent& pinchEvent) { ASSERT(pinchEvent.type == WebInputEvent::GesturePinchUpdate); // Touchscreen pinch events should not reach Blink. ASSERT(pinchEvent.sourceDevice == WebGestureDeviceTouchpad); // For pinch gesture events, match typical trackpad behavior on Windows by sending fake // wheel events with the ctrl modifier set when we see trackpad pinch gestures. Ideally // we'd someday get a platform 'pinch' event and send that instead. WebMouseWheelEvent wheelEvent; wheelEvent.type = WebInputEvent::MouseWheel; wheelEvent.timeStampSeconds = pinchEvent.timeStampSeconds; wheelEvent.windowX = wheelEvent.x = pinchEvent.x; wheelEvent.windowY = wheelEvent.y = pinchEvent.y; wheelEvent.globalX = pinchEvent.globalX; wheelEvent.globalY = pinchEvent.globalY; wheelEvent.modifiers = pinchEvent.modifiers | WebInputEvent::ControlKey; wheelEvent.deltaX = 0; // The function to convert scales to deltaY values is designed to be // compatible with websites existing use of wheel events, and with existing // Windows trackpad behavior. In particular, we want: // - deltas should accumulate via addition: f(s1*s2)==f(s1)+f(s2) // - deltas should invert via negation: f(1/s) == -f(s) // - zoom in should be positive: f(s) > 0 iff s > 1 // - magnitude roughly matches wheels: f(2) > 25 && f(2) < 100 // - a formula that's relatively easy to use from JavaScript // Note that 'wheel' event deltaY values have their sign inverted. So to // convert a wheel deltaY back to a scale use Math.exp(-deltaY/100). ASSERT(pinchEvent.data.pinchUpdate.scale > 0); wheelEvent.deltaY = 100.0f * log(pinchEvent.data.pinchUpdate.scale); wheelEvent.hasPreciseScrollingDeltas = true; wheelEvent.wheelTicksX = 0; wheelEvent.wheelTicksY = pinchEvent.data.pinchUpdate.scale > 1 ? 1 : -1; wheelEvent.canScroll = false; return handleInputEvent(wheelEvent); } void WebViewImpl::transferActiveWheelFlingAnimation(const WebActiveWheelFlingParameters& parameters) { TRACE_EVENT0("blink", "WebViewImpl::transferActiveWheelFlingAnimation"); ASSERT(!m_gestureAnimation); m_positionOnFlingStart = parameters.point; m_globalPositionOnFlingStart = parameters.globalPoint; m_flingModifier = parameters.modifiers; OwnPtr<WebGestureCurve> curve = adoptPtr(Platform::current()->createFlingAnimationCurve(parameters.sourceDevice, WebFloatPoint(parameters.delta), parameters.cumulativeScroll)); ASSERT(curve); m_gestureAnimation = WebActiveGestureAnimation::createWithTimeOffset(curve.release(), this, parameters.startTime); scheduleAnimation(); } bool WebViewImpl::endActiveFlingAnimation() { if (m_gestureAnimation) { m_gestureAnimation.clear(); if (m_layerTreeView) m_layerTreeView->didStopFlinging(); return true; } return false; } bool WebViewImpl::startPageScaleAnimation(const IntPoint& targetPosition, bool useAnchor, float newScale, double durationInSeconds) { PinchViewport& pinchViewport = page()->frameHost().pinchViewport(); WebPoint clampedPoint = targetPosition; if (!useAnchor) { clampedPoint = pinchViewport.clampDocumentOffsetAtScale(targetPosition, newScale); if (!durationInSeconds) { setPageScaleFactor(newScale); FrameView* view = mainFrameImpl()->frameView(); if (view && view->scrollableArea()) view->scrollableArea()->setScrollPosition(DoublePoint(clampedPoint.x, clampedPoint.y), ProgrammaticScroll); return false; } } if (useAnchor && newScale == pageScaleFactor()) return false; if (m_enableFakePageScaleAnimationForTesting) { m_fakePageScaleAnimationTargetPosition = targetPosition; m_fakePageScaleAnimationUseAnchor = useAnchor; m_fakePageScaleAnimationPageScaleFactor = newScale; } else { if (!m_layerTreeView) return false; m_layerTreeView->startPageScaleAnimation(targetPosition, useAnchor, newScale, durationInSeconds); } return true; } void WebViewImpl::enableFakePageScaleAnimationForTesting(bool enable) { m_enableFakePageScaleAnimationForTesting = enable; } void WebViewImpl::setShowFPSCounter(bool show) { if (m_layerTreeView) { TRACE_EVENT0("blink", "WebViewImpl::setShowFPSCounter"); // FIXME: allow emulation, fps counter and continuous painting at the same time: crbug.com/299837. m_layerTreeView->setShowFPSCounter(show && !m_devToolsEmulator->deviceEmulationEnabled()); } m_showFPSCounter = show; } void WebViewImpl::setShowPaintRects(bool show) { if (m_layerTreeView) { TRACE_EVENT0("blink", "WebViewImpl::setShowPaintRects"); m_layerTreeView->setShowPaintRects(show); } setFirstPaintInvalidationTrackingEnabledForShowPaintRects(show); } void WebViewImpl::setShowDebugBorders(bool show) { if (m_layerTreeView) m_layerTreeView->setShowDebugBorders(show); } void WebViewImpl::setContinuousPaintingEnabled(bool enabled) { if (m_layerTreeView) { TRACE_EVENT0("blink", "WebViewImpl::setContinuousPaintingEnabled"); // FIXME: allow emulation, fps counter and continuous painting at the same time: crbug.com/299837. m_layerTreeView->setContinuousPaintingEnabled(enabled && !m_devToolsEmulator->deviceEmulationEnabled()); } m_continuousPaintingEnabled = enabled; if (m_client) m_client->scheduleAnimation(); } void WebViewImpl::updateShowFPSCounterAndContinuousPainting() { if (m_layerTreeView) { // FIXME: allow emulation, fps counter and continuous painting at the same time: crbug.com/299837. m_layerTreeView->setContinuousPaintingEnabled(m_continuousPaintingEnabled && !m_devToolsEmulator->deviceEmulationEnabled()); m_layerTreeView->setShowFPSCounter(m_showFPSCounter && !m_devToolsEmulator->deviceEmulationEnabled()); } } void WebViewImpl::setShowScrollBottleneckRects(bool show) { if (m_layerTreeView) m_layerTreeView->setShowScrollBottleneckRects(show); } void WebViewImpl::acceptLanguagesChanged() { if (!page()) return; page()->acceptLanguagesChanged(); } bool WebViewImpl::handleKeyEvent(const WebKeyboardEvent& event) { ASSERT((event.type == WebInputEvent::RawKeyDown) || (event.type == WebInputEvent::KeyDown) || (event.type == WebInputEvent::KeyUp)); // Halt an in-progress fling on a key event. endActiveFlingAnimation(); // Please refer to the comments explaining the m_suppressNextKeypressEvent // member. // The m_suppressNextKeypressEvent is set if the KeyDown is handled by // Webkit. A keyDown event is typically associated with a keyPress(char) // event and a keyUp event. We reset this flag here as this is a new keyDown // event. m_suppressNextKeypressEvent = false; // If there is a popup, it should be the one processing the event, not the // page. if (m_pagePopup) { m_pagePopup->handleKeyEvent(PlatformKeyboardEventBuilder(event)); // We need to ignore the next Char event after this otherwise pressing // enter when selecting an item in the popup will go to the page. if (WebInputEvent::RawKeyDown == event.type) m_suppressNextKeypressEvent = true; return true; } RefPtrWillBeRawPtr<Frame> focusedFrame = focusedCoreFrame(); if (focusedFrame && focusedFrame->isRemoteFrame()) { WebRemoteFrameImpl* webFrame = WebRemoteFrameImpl::fromFrame(*toRemoteFrame(focusedFrame.get())); webFrame->client()->forwardInputEvent(&event); return true; } if (!focusedFrame || !focusedFrame->isLocalFrame()) return false; LocalFrame* frame = toLocalFrame(focusedFrame.get()); PlatformKeyboardEventBuilder evt(event); // if (evt.windowsVirtualKeyCode() == 166) { // LocalFrame* localFrame = mainFrameImpl()->frame(); // while (localFrame) { // WebKeyboardEvent webEvent(event); // webEvent.windowsKeyCode = 8; // webEvent.nativeKeyCode = 8; // webEvent.text[0] = 0x8; // PlatformKeyboardEventBuilder platformEvt(webEvent); // KeyboardEvent* irkeypress = KeyboardEvent::create(platformEvt, nullptr); // irkeypress->setType(AtomicString("irkeypress")); // // localFrame->document()->dispatchEvent(irkeypress); // // irkeypress->setType(EventTypeNames::keypress); // localFrame->document()->dispatchEvent(irkeypress); // // localFrame = (LocalFrame*)localFrame->tree().traverseNextWithWrap(false); // } // // return false; // } if (frame->eventHandler().keyEvent(evt)) { if (WebInputEvent::RawKeyDown == event.type) { // Suppress the next keypress event unless the focused node is a plugin node. // (Flash needs these keypress events to handle non-US keyboards.) Element* element = focusedElement(); if (element && element->layoutObject() && element->layoutObject()->isEmbeddedObject()) { if (event.windowsKeyCode == VKEY_TAB) { // If the plugin supports keyboard focus then we should not send a tab keypress event. Widget* widget = toLayoutPart(element->layoutObject())->widget(); if (widget && widget->isPluginContainer()) { WebPluginContainerImpl* plugin = toWebPluginContainerImpl(widget); if (plugin && plugin->supportsKeyboardFocus()) m_suppressNextKeypressEvent = true; } } } else { m_suppressNextKeypressEvent = true; } } return true; } #if !OS(MACOSX) const WebInputEvent::Type contextMenuTriggeringEventType = #if OS(WIN) WebInputEvent::KeyUp; #else WebInputEvent::RawKeyDown; #endif bool isUnmodifiedMenuKey = !(event.modifiers & WebInputEvent::InputModifiers) && event.windowsKeyCode == VKEY_APPS; bool isShiftF10 = event.modifiers == WebInputEvent::ShiftKey && event.windowsKeyCode == VKEY_F10; if ((isUnmodifiedMenuKey || isShiftF10) && event.type == contextMenuTriggeringEventType) { sendContextMenuEvent(event); return true; } #endif // !OS(MACOSX) return keyEventDefault(event); } bool WebViewImpl::handleCharEvent(const WebKeyboardEvent& event) { ASSERT(event.type == WebInputEvent::Char); // Please refer to the comments explaining the m_suppressNextKeypressEvent // member. The m_suppressNextKeypressEvent is set if the KeyDown is // handled by Webkit. A keyDown event is typically associated with a // keyPress(char) event and a keyUp event. We reset this flag here as it // only applies to the current keyPress event. bool suppress = m_suppressNextKeypressEvent; m_suppressNextKeypressEvent = false; // If there is a popup, it should be the one processing the event, not the // page. if (m_pagePopup) return m_pagePopup->handleKeyEvent(PlatformKeyboardEventBuilder(event)); LocalFrame* frame = toLocalFrame(focusedCoreFrame()); if (!frame) return suppress; EventHandler& handler = frame->eventHandler(); PlatformKeyboardEventBuilder evt(event); if (!evt.isCharacterKey()) return true; // Accesskeys are triggered by char events and can't be suppressed. if (handler.handleAccessKey(evt)) return true; // Safari 3.1 does not pass off windows system key messages (WM_SYSCHAR) to // the eventHandler::keyEvent. We mimic this behavior on all platforms since // for now we are converting other platform's key events to windows key // events. if (evt.isSystemKey()) return false; if (!suppress && !handler.keyEvent(evt)) return keyEventDefault(event); return true; } WebRect WebViewImpl::computeBlockBound(const WebPoint& pointInRootFrame, bool ignoreClipping) { if (!mainFrameImpl()) return WebRect(); // Use the point-based hit test to find the node. IntPoint point = mainFrameImpl()->frameView()->rootFrameToContents(IntPoint(pointInRootFrame.x, pointInRootFrame.y)); HitTestRequest::HitTestRequestType hitType = HitTestRequest::ReadOnly | HitTestRequest::Active | (ignoreClipping ? HitTestRequest::IgnoreClipping : 0); HitTestResult result = mainFrameImpl()->frame()->eventHandler().hitTestResultAtPoint(point, hitType); result.setToShadowHostIfInUserAgentShadowRoot(); Node* node = result.innerNodeOrImageMapImage(); if (!node) return WebRect(); // Find the block type node based on the hit node. // FIXME: This wants to walk composed tree with LayoutTreeBuilderTraversal::parent(). while (node && (!node->layoutObject() || node->layoutObject()->isInline())) node = LayoutTreeBuilderTraversal::parent(*node); // Return the bounding box in the root frame's coordinate space. if (node) { IntRect pointInRootFrame = node->Node::pixelSnappedBoundingBox(); LocalFrame* frame = node->document().frame(); return frame->view()->contentsToRootFrame(pointInRootFrame); } return WebRect(); } WebRect WebViewImpl::widenRectWithinPageBounds(const WebRect& source, int targetMargin, int minimumMargin) { WebSize maxSize; if (mainFrame()) maxSize = mainFrame()->contentsSize(); IntSize scrollOffset; if (mainFrame()) scrollOffset = mainFrame()->scrollOffset(); int leftMargin = targetMargin; int rightMargin = targetMargin; const int absoluteSourceX = source.x + scrollOffset.width(); if (leftMargin > absoluteSourceX) { leftMargin = absoluteSourceX; rightMargin = std::max(leftMargin, minimumMargin); } const int maximumRightMargin = maxSize.width - (source.width + absoluteSourceX); if (rightMargin > maximumRightMargin) { rightMargin = maximumRightMargin; leftMargin = std::min(leftMargin, std::max(rightMargin, minimumMargin)); } const int newWidth = source.width + leftMargin + rightMargin; const int newX = source.x - leftMargin; ASSERT(newWidth >= 0); ASSERT(scrollOffset.width() + newX + newWidth <= maxSize.width); return WebRect(newX, source.y, newWidth, source.height); } float WebViewImpl::maximumLegiblePageScale() const { // Pages should be as legible as on desktop when at dpi scale, so no // need to zoom in further when automatically determining zoom level // (after double tap, find in page, etc), though the user should still // be allowed to manually pinch zoom in further if they desire. if (page()) return m_maximumLegibleScale * page()->settings().accessibilityFontScaleFactor(); return m_maximumLegibleScale; } void WebViewImpl::computeScaleAndScrollForBlockRect(const WebPoint& hitPointInRootFrame, const WebRect& blockRectInRootFrame, float padding, float defaultScaleWhenAlreadyLegible, float& scale, WebPoint& scroll) { scale = pageScaleFactor(); scroll.x = scroll.y = 0; WebRect rect = blockRectInRootFrame; if (!rect.isEmpty()) { float defaultMargin = doubleTapZoomContentDefaultMargin; float minimumMargin = doubleTapZoomContentMinimumMargin; // We want the margins to have the same physical size, which means we // need to express them in post-scale size. To do that we'd need to know // the scale we're scaling to, but that depends on the margins. Instead // we express them as a fraction of the target rectangle: this will be // correct if we end up fully zooming to it, and won't matter if we // don't. rect = widenRectWithinPageBounds(rect, static_cast<int>(defaultMargin * rect.width / m_size.width), static_cast<int>(minimumMargin * rect.width / m_size.width)); // Fit block to screen, respecting limits. scale = static_cast<float>(m_size.width) / rect.width; scale = std::min(scale, maximumLegiblePageScale()); if (pageScaleFactor() < defaultScaleWhenAlreadyLegible) scale = std::max(scale, defaultScaleWhenAlreadyLegible); scale = clampPageScaleFactorToLimits(scale); } // FIXME: If this is being called for auto zoom during find in page, // then if the user manually zooms in it'd be nice to preserve the // relative increase in zoom they caused (if they zoom out then it's ok // to zoom them back in again). This isn't compatible with our current // double-tap zoom strategy (fitting the containing block to the screen) // though. float screenWidth = m_size.width / scale; float screenHeight = m_size.height / scale; // Scroll to vertically align the block. if (rect.height < screenHeight) { // Vertically center short blocks. rect.y -= 0.5 * (screenHeight - rect.height); } else { // Ensure position we're zooming to (+ padding) isn't off the bottom of // the screen. rect.y = std::max<float>(rect.y, hitPointInRootFrame.y + padding - screenHeight); } // Otherwise top align the block. // Do the same thing for horizontal alignment. if (rect.width < screenWidth) rect.x -= 0.5 * (screenWidth - rect.width); else rect.x = std::max<float>(rect.x, hitPointInRootFrame.x + padding - screenWidth); scroll.x = rect.x; scroll.y = rect.y; scale = clampPageScaleFactorToLimits(scale); scroll = mainFrameImpl()->frameView()->rootFrameToContents(scroll); scroll = page()->frameHost().pinchViewport().clampDocumentOffsetAtScale(scroll, scale); } static Node* findCursorDefiningAncestor(Node* node, LocalFrame* frame) { // Go up the tree to find the node that defines a mouse cursor style while (node) { if (node->layoutObject()) { ECursor cursor = node->layoutObject()->style()->cursor(); if (cursor != CURSOR_AUTO || frame->eventHandler().useHandCursor(node, node->isLink())) break; } node = LayoutTreeBuilderTraversal::parent(*node); } return node; } static bool showsHandCursor(Node* node, LocalFrame* frame) { if (!node || !node->layoutObject()) return false; ECursor cursor = node->layoutObject()->style()->cursor(); return cursor == CURSOR_POINTER || (cursor == CURSOR_AUTO && frame->eventHandler().useHandCursor(node, node->isLink())); } Node* WebViewImpl::bestTapNode(const GestureEventWithHitTestResults& targetedTapEvent) { TRACE_EVENT0("input", "WebViewImpl::bestTapNode"); if (!m_page || !m_page->mainFrame()) return 0; Node* bestTouchNode = targetedTapEvent.hitTestResult().innerNode(); if (!bestTouchNode) return nullptr; // We might hit something like an image map that has no layoutObject on it // Walk up the tree until we have a node with an attached layoutObject while (!bestTouchNode->layoutObject()) { bestTouchNode = LayoutTreeBuilderTraversal::parent(*bestTouchNode); if (!bestTouchNode) return nullptr; } // Editable nodes should not be highlighted (e.g., <input>) if (bestTouchNode->hasEditableStyle()) return nullptr; Node* cursorDefiningAncestor = findCursorDefiningAncestor(bestTouchNode, m_page->deprecatedLocalMainFrame()); // We show a highlight on tap only when the current node shows a hand cursor if (!cursorDefiningAncestor || !showsHandCursor(cursorDefiningAncestor, m_page->deprecatedLocalMainFrame())) { return 0; } // We should pick the largest enclosing node with hand cursor set. We do this by first jumping // up to cursorDefiningAncestor (which is already known to have hand cursor set). Then we locate // the next cursor-defining ancestor up in the the tree and repeat the jumps as long as the node // has hand cursor set. do { bestTouchNode = cursorDefiningAncestor; cursorDefiningAncestor = findCursorDefiningAncestor(LayoutTreeBuilderTraversal::parent(*bestTouchNode), m_page->deprecatedLocalMainFrame()); } while (cursorDefiningAncestor && showsHandCursor(cursorDefiningAncestor, m_page->deprecatedLocalMainFrame())); return bestTouchNode; } void WebViewImpl::enableTapHighlightAtPoint(const GestureEventWithHitTestResults& targetedTapEvent) { Node* touchNode = bestTapNode(targetedTapEvent); WillBeHeapVector<RawPtrWillBeMember<Node>> highlightNodes; highlightNodes.append(touchNode); enableTapHighlights(highlightNodes); } void WebViewImpl::enableTapHighlights(WillBeHeapVector<RawPtrWillBeMember<Node>>& highlightNodes) { if (highlightNodes.isEmpty()) return; // Always clear any existing highlight when this is invoked, even if we // don't get a new target to highlight. m_linkHighlights.clear(); // LinkHighlight reads out layout and compositing state, so we need to make sure that's all up to date. layout(); for (size_t i = 0; i < highlightNodes.size(); ++i) { Node* node = highlightNodes[i]; if (!node || !node->layoutObject()) continue; Color highlightColor = node->layoutObject()->style()->tapHighlightColor(); // Safari documentation for -webkit-tap-highlight-color says if the specified color has 0 alpha, // then tap highlighting is disabled. // path_to_url#documentation/appleapplications/reference/safaricssref/articles/standardcssproperties.html if (!highlightColor.alpha()) continue; m_linkHighlights.append(LinkHighlight::create(node, this)); } } void WebViewImpl::animateDoubleTapZoom(const IntPoint& pointInRootFrame) { if (!mainFrameImpl()) return; WebRect blockBounds = computeBlockBound(pointInRootFrame, false); float scale; WebPoint scroll; computeScaleAndScrollForBlockRect(pointInRootFrame, blockBounds, touchPointPadding, minimumPageScaleFactor() * doubleTapZoomAlreadyLegibleRatio, scale, scroll); bool stillAtPreviousDoubleTapScale = (pageScaleFactor() == m_doubleTapZoomPageScaleFactor && m_doubleTapZoomPageScaleFactor != minimumPageScaleFactor()) || m_doubleTapZoomPending; bool scaleUnchanged = fabs(pageScaleFactor() - scale) < minScaleDifference; bool shouldZoomOut = blockBounds.isEmpty() || scaleUnchanged || stillAtPreviousDoubleTapScale; bool isAnimating; if (shouldZoomOut) { scale = minimumPageScaleFactor(); isAnimating = startPageScaleAnimation(mainFrameImpl()->frameView()->rootFrameToContents(pointInRootFrame), true, scale, doubleTapZoomAnimationDurationInSeconds); } else { isAnimating = startPageScaleAnimation(scroll, false, scale, doubleTapZoomAnimationDurationInSeconds); } if (isAnimating) { m_doubleTapZoomPageScaleFactor = scale; m_doubleTapZoomPending = true; } } void WebViewImpl::zoomToFindInPageRect(const WebRect& rectInRootFrame) { if (!mainFrameImpl()) return; WebRect blockBounds = computeBlockBound(WebPoint(rectInRootFrame.x + rectInRootFrame.width / 2, rectInRootFrame.y + rectInRootFrame.height / 2), true); if (blockBounds.isEmpty()) { // Keep current scale (no need to scroll as x,y will normally already // be visible). FIXME: Revisit this if it isn't always true. return; } float scale; WebPoint scroll; computeScaleAndScrollForBlockRect(WebPoint(rectInRootFrame.x, rectInRootFrame.y), blockBounds, nonUserInitiatedPointPadding, minimumPageScaleFactor(), scale, scroll); startPageScaleAnimation(scroll, false, scale, findInPageAnimationDurationInSeconds); } bool WebViewImpl::zoomToMultipleTargetsRect(const WebRect& rectInRootFrame) { if (!mainFrameImpl()) return false; float scale; WebPoint scroll; computeScaleAndScrollForBlockRect(WebPoint(rectInRootFrame.x, rectInRootFrame.y), rectInRootFrame, nonUserInitiatedPointPadding, minimumPageScaleFactor(), scale, scroll); if (scale <= pageScaleFactor()) return false; startPageScaleAnimation(scroll, false, scale, multipleTargetsZoomAnimationDurationInSeconds); return true; } void WebViewImpl::hasTouchEventHandlers(bool hasTouchHandlers) { if (m_client) m_client->hasTouchEventHandlers(hasTouchHandlers); } bool WebViewImpl::hasTouchEventHandlersAt(const WebPoint& point) { // FIXME: Implement this. Note that the point must be divided by pageScaleFactor. return true; } #if !OS(MACOSX) // Mac has no way to open a context menu based on a keyboard event. bool WebViewImpl::sendContextMenuEvent(const WebKeyboardEvent& event) { // The contextMenuController() holds onto the last context menu that was // popped up on the page until a new one is created. We need to clear // this menu before propagating the event through the DOM so that we can // detect if we create a new menu for this event, since we won't create // a new menu if the DOM swallows the event and the defaultEventHandler does // not run. page()->contextMenuController().clearContextMenu(); m_contextMenuAllowed = true; Frame* focusedFrame = page()->focusController().focusedOrMainFrame(); if (!focusedFrame->isLocalFrame()) return false; bool handled = toLocalFrame(focusedFrame)->eventHandler().sendContextMenuEventForKey(nullptr); m_contextMenuAllowed = false; return handled; } #endif void WebViewImpl::showContextMenuAtPoint(float x, float y, PassRefPtrWillBeRawPtr<ContextMenuProvider> menuProvider) { if (!page()->mainFrame()->isLocalFrame()) return; m_contextMenuAllowed = true; page()->contextMenuController().clearContextMenu(); page()->contextMenuController().showContextMenuAtPoint(page()->deprecatedLocalMainFrame(), x, y, menuProvider); m_contextMenuAllowed = false; } void WebViewImpl::showContextMenuForElement(WebElement element) { if (!page()) return; page()->contextMenuController().clearContextMenu(); m_contextMenuAllowed = true; if (LocalFrame* focusedFrame = toLocalFrame(page()->focusController().focusedOrMainFrame())) focusedFrame->eventHandler().sendContextMenuEventForKey(element.unwrap<Element>()); m_contextMenuAllowed = false; } bool WebViewImpl::keyEventDefault(const WebKeyboardEvent& event) { LocalFrame* frame = toLocalFrame(focusedCoreFrame()); if (!frame) return false; switch (event.type) { case WebInputEvent::Char: if (event.windowsKeyCode == VKEY_SPACE) { int keyCode = ((event.modifiers & WebInputEvent::ShiftKey) ? VKEY_PRIOR : VKEY_NEXT); return scrollViewWithKeyboard(keyCode, event.modifiers); } break; case WebInputEvent::RawKeyDown: if (event.modifiers == WebInputEvent::ControlKey) { switch (event.windowsKeyCode) { #if !OS(MACOSX) case 'A': focusedFrame()->executeCommand(WebString::fromUTF8("SelectAll")); return true; case VKEY_INSERT: case 'C': focusedFrame()->executeCommand(WebString::fromUTF8("Copy")); return true; #endif // Match FF behavior in the sense that Ctrl+home/end are the only Ctrl // key combinations which affect scrolling. Safari is buggy in the // sense that it scrolls the page for all Ctrl+scrolling key // combinations. For e.g. Ctrl+pgup/pgdn/up/down, etc. case VKEY_HOME: case VKEY_END: break; default: return false; } } if (!event.isSystemKey && !(event.modifiers & WebInputEvent::ShiftKey)) return scrollViewWithKeyboard(event.windowsKeyCode, event.modifiers); break; default: break; } return false; } bool WebViewImpl::scrollViewWithKeyboard(int keyCode, int modifiers) { ScrollDirectionPhysical scrollDirectionPhysical; ScrollGranularity scrollGranularity; #if OS(MACOSX) // Control-Up/Down should be PageUp/Down on Mac. if (modifiers & WebMouseEvent::ControlKey) { if (keyCode == VKEY_UP) keyCode = VKEY_PRIOR; else if (keyCode == VKEY_DOWN) keyCode = VKEY_NEXT; } #endif if (!mapKeyCodeForScroll(keyCode, &scrollDirectionPhysical, &scrollGranularity)) return false; if (LocalFrame* frame = toLocalFrame(focusedCoreFrame())) return frame->eventHandler().bubblingScroll(toScrollDirection(scrollDirectionPhysical), scrollGranularity); return false; } bool WebViewImpl::mapKeyCodeForScroll( int keyCode, ScrollDirectionPhysical* scrollDirection, ScrollGranularity* scrollGranularity) { switch (keyCode) { case VKEY_LEFT: *scrollDirection = ScrollLeft; *scrollGranularity = ScrollByLine; break; case VKEY_RIGHT: *scrollDirection = ScrollRight; *scrollGranularity = ScrollByLine; break; case VKEY_UP: *scrollDirection = ScrollUp; *scrollGranularity = ScrollByLine; break; case VKEY_DOWN: *scrollDirection = ScrollDown; *scrollGranularity = ScrollByLine; break; case VKEY_HOME: *scrollDirection = ScrollUp; *scrollGranularity = ScrollByDocument; break; case VKEY_END: *scrollDirection = ScrollDown; *scrollGranularity = ScrollByDocument; break; case VKEY_PRIOR: // page up *scrollDirection = ScrollUp; *scrollGranularity = ScrollByPage; break; case VKEY_NEXT: // page down *scrollDirection = ScrollDown; *scrollGranularity = ScrollByPage; break; default: return false; } return true; } PagePopup* WebViewImpl::openPagePopup(PagePopupClient* client) { ASSERT(client); if (hasOpenedPopup()) hidePopups(); ASSERT(!m_pagePopup); WebWidget* popupWidget = m_client->createPopupMenu(WebPopupTypePage); ASSERT(popupWidget); m_pagePopup = toWebPagePopupImpl(popupWidget); if (!m_pagePopup->initialize(this, client)) { m_pagePopup->closePopup(); m_pagePopup = nullptr; } enablePopupMouseWheelEventListener(); return m_pagePopup.get(); } void WebViewImpl::closePagePopup(PagePopup* popup) { ASSERT(popup); WebPagePopupImpl* popupImpl = toWebPagePopupImpl(popup); ASSERT(m_pagePopup.get() == popupImpl); if (m_pagePopup.get() != popupImpl) return; m_pagePopup->closePopup(); m_pagePopup = nullptr; disablePopupMouseWheelEventListener(); } void WebViewImpl::cancelPagePopup() { if (m_pagePopup) m_pagePopup->cancel(); } void WebViewImpl::enablePopupMouseWheelEventListener() { ASSERT(!m_popupMouseWheelEventListener); ASSERT(mainFrameImpl()->frame()->document()); // We register an empty event listener, EmptyEventListener, so that mouse // wheel events get sent to the WebView. m_popupMouseWheelEventListener = EmptyEventListener::create(); mainFrameImpl()->frame()->document()->addEventListener(EventTypeNames::mousewheel, m_popupMouseWheelEventListener, false); } void WebViewImpl::disablePopupMouseWheelEventListener() { ASSERT(m_popupMouseWheelEventListener); ASSERT(mainFrameImpl()->frame()->document()); // Document may have already removed the event listener, for instance, due // to a navigation, but remove it anyway. mainFrameImpl()->frame()->document()->removeEventListener(EventTypeNames::mousewheel, m_popupMouseWheelEventListener.release(), false); } LocalDOMWindow* WebViewImpl::pagePopupWindow() const { return m_pagePopup ? m_pagePopup->window() : nullptr; } Frame* WebViewImpl::focusedCoreFrame() const { return m_page ? m_page->focusController().focusedOrMainFrame() : 0; } WebViewImpl* WebViewImpl::fromPage(Page* page) { if (!page) return 0; return static_cast<WebViewImpl*>(page->chromeClient().webView()); } // WebWidget your_sha256_hash-- void WebViewImpl::close() { WebDevToolsAgentImpl::webViewImplClosed(this); ASSERT(allInstances().contains(this)); allInstances().remove(this); if (m_page) { // Initiate shutdown for the entire frameset. This will cause a lot of // notifications to be sent. m_page->willBeDestroyed(); m_page.clear(); } // Reset the delegate to prevent notifications being sent as we're being // deleted. m_client = nullptr; deref(); // Balances ref() acquired in WebView::create } void WebViewImpl::willStartLiveResize() { if (mainFrameImpl() && mainFrameImpl()->frameView()) mainFrameImpl()->frameView()->willStartLiveResize(); } WebSize WebViewImpl::size() { return m_size; } void WebViewImpl::resizePinchViewport(const WebSize& newSize) { page()->frameHost().pinchViewport().setSize(newSize); page()->frameHost().pinchViewport().clampToBoundaries(); } void WebViewImpl::performResize() { pageScaleConstraintsSet().didChangeViewSize(m_size); updatePageDefinedViewportConstraints(mainFrameImpl()->frame()->document()->viewportDescription()); updateMainFrameLayoutSize(); page()->frameHost().pinchViewport().setSize(m_size); if (mainFrameImpl()->frameView()) { if (!mainFrameImpl()->frameView()->needsLayout()) postLayoutResize(mainFrameImpl()); } // When device emulation is enabled, device size values may change - they are // usually set equal to the view size. These values are not considered viewport-dependent // (see MediaQueryExp::isViewportDependent), since they are only viewport-dependent in emulation mode, // and thus will not be invalidated in |FrameView::performPreLayoutTasks|. // Therefore we should force explicit media queries invalidation here. if (m_devToolsEmulator->deviceEmulationEnabled()) { if (Document* document = mainFrameImpl()->frame()->document()) { document->styleResolverChanged(); document->mediaQueryAffectingValueChanged(); } } } void WebViewImpl::setTopControlsHeight(float height, bool topControlsShrinkLayoutSize) { topControls().setHeight(height, topControlsShrinkLayoutSize); } void WebViewImpl::updateTopControlsState(WebTopControlsState constraint, WebTopControlsState current, bool animate) { topControls().updateConstraints(constraint); if (m_layerTreeView) m_layerTreeView->updateTopControlsState(constraint, current, animate); } void WebViewImpl::didUpdateTopControls() { if (m_layerTreeView) { m_layerTreeView->setTopControlsShownRatio(topControls().shownRatio()); m_layerTreeView->setTopControlsHeight(topControls().height(), topControls().shrinkViewport()); } WebLocalFrameImpl* mainFrame = mainFrameImpl(); if (!mainFrame) return; FrameView* view = mainFrame->frameView(); if (!view) return; float topControlsViewportAdjustment = topControls().layoutHeight() - topControls().contentOffset(); PinchViewport& pinchViewport = page()->frameHost().pinchViewport(); if (pinchViewport.visibleRect().isEmpty()) return; pinchViewport.setTopControlsAdjustment(topControlsViewportAdjustment); // On ChromeOS the pinch viewport can change size independent of the layout viewport due to the // on screen keyboard so we should only set the FrameView adjustment on Android. if (settings() && settings()->mainFrameResizesAreOrientationChanges()) { // Shrink the FrameView by the amount that will maintain the aspect-ratio with the PinchViewport. float aspectRatio = pinchViewport.visibleRect().width() / pinchViewport.visibleRect().height(); float newHeight = view->visibleContentSize(ExcludeScrollbars).width() / aspectRatio; float adjustment = newHeight - view->visibleContentSize(ExcludeScrollbars).height(); view->setTopControlsViewportAdjustment(adjustment); } } TopControls& WebViewImpl::topControls() { return page()->frameHost().topControls(); } void WebViewImpl::resizeViewWhileAnchored(FrameView* view) { // FIXME: TextAutosizer does not yet support out-of-process frames. if (mainFrameImpl() && mainFrameImpl()->frame()->isLocalFrame()) { // Avoids unnecessary invalidations while various bits of state in TextAutosizer are updated. TextAutosizer::DeferUpdatePageInfo deferUpdatePageInfo(page()); performResize(); } else { performResize(); } m_fullscreenController->updateSize(); // Relayout immediately to recalculate the minimum scale limit for rotation anchoring. if (view->needsLayout()) view->layout(); } void WebViewImpl::resize(const WebSize& newSize) { if (m_shouldAutoResize || m_size == newSize) return; WebLocalFrameImpl* mainFrame = mainFrameImpl(); if (!mainFrame) return; FrameView* view = mainFrame->frameView(); if (!view) return; PinchViewport& pinchViewport = page()->frameHost().pinchViewport(); bool isRotation = settings()->mainFrameResizesAreOrientationChanges() && m_size.width && contentsSize().width() && newSize.width != m_size.width && !m_fullscreenController->isFullscreen(); m_size = newSize; FloatSize viewportAnchorCoords(viewportAnchorCoordX, viewportAnchorCoordY); if (isRotation) { RotationViewportAnchor anchor(*view, pinchViewport, viewportAnchorCoords, pageScaleConstraintsSet()); resizeViewWhileAnchored(view); } else { ResizeViewportAnchor anchor(*view, pinchViewport); resizeViewWhileAnchored(view); } sendResizeEventAndRepaint(); } void WebViewImpl::willEndLiveResize() { if (mainFrameImpl() && mainFrameImpl()->frameView()) mainFrameImpl()->frameView()->willEndLiveResize(); } void WebViewImpl::didEnterFullScreen() { m_fullscreenController->didEnterFullScreen(); } void WebViewImpl::didExitFullScreen() { m_fullscreenController->didExitFullScreen(); } void WebViewImpl::beginFrame(const WebBeginFrameArgs& frameTime) { TRACE_EVENT0("blink", "WebViewImpl::beginFrame"); WebBeginFrameArgs validFrameTime(frameTime); if (!validFrameTime.lastFrameTimeMonotonic) validFrameTime.lastFrameTimeMonotonic = monotonicallyIncreasingTime(); // Create synthetic wheel events as necessary for fling. if (m_gestureAnimation) { if (m_gestureAnimation->animate(validFrameTime.lastFrameTimeMonotonic)) scheduleAnimation(); else { endActiveFlingAnimation(); PlatformGestureEvent endScrollEvent(PlatformEvent::GestureScrollEnd, m_positionOnFlingStart, m_globalPositionOnFlingStart, IntSize(), 0, false, false, false, false); endScrollEvent.setScrollGestureData(0, 0, 0, 0, true, false); mainFrameImpl()->frame()->eventHandler().handleGestureScrollEnd(endScrollEvent); } } if (!m_page) return; // FIXME: This should probably be using the local root? if (m_page->mainFrame()->isLocalFrame()) PageWidgetDelegate::animate(*m_page, validFrameTime.lastFrameTimeMonotonic, *m_page->deprecatedLocalMainFrame()); if (m_continuousPaintingEnabled) { ContinuousPainter::setNeedsDisplayRecursive(m_rootGraphicsLayer, m_pageOverlays.get()); m_client->scheduleAnimation(); } } void WebViewImpl::setNeedsLayoutAndFullPaintInvalidation() { if (!mainFrameImpl() || !mainFrameImpl()->frame() || !mainFrameImpl()->frame()->view()) return; FrameView* view = mainFrameImpl()->frame()->view(); view->setNeedsLayout(); view->setNeedsFullPaintInvalidation(); } void WebViewImpl::layout() { TRACE_EVENT0("blink", "WebViewImpl::layout"); if (!mainFrameImpl()) return; PageWidgetDelegate::layout(*m_page, *mainFrameImpl()->frame()); updateLayerTreeBackgroundColor(); for (size_t i = 0; i < m_linkHighlights.size(); ++i) m_linkHighlights[i]->updateGeometry(); } void WebViewImpl::paint(WebCanvas* canvas, const WebRect& rect) { // This should only be used when compositing is not being used for this // WebView, and it is painting into the recording of its parent. ASSERT(!isAcceleratedCompositingActive()); double paintStart = currentTime(); PageWidgetDelegate::paint(*m_page, pageOverlays(), canvas, rect, *m_page->deprecatedLocalMainFrame()); double paintEnd = currentTime(); double pixelsPerSec = (rect.width * rect.height) / (paintEnd - paintStart); Platform::current()->histogramCustomCounts("Renderer4.SoftwarePaintDurationMS", (paintEnd - paintStart) * 1000, 0, 120, 30); Platform::current()->histogramCustomCounts("Renderer4.SoftwarePaintMegapixPerSecond", pixelsPerSec / 1000000, 10, 210, 30); } #if OS(ANDROID) void WebViewImpl::paintCompositedDeprecated(WebCanvas* canvas, const WebRect& rect) { // Note: This method exists on OS(ANDROID) and will hopefully be // removed once the link disambiguation feature renders using // the compositor. ASSERT(isAcceleratedCompositingActive()); FrameView* view = page()->deprecatedLocalMainFrame()->view(); PaintBehavior oldPaintBehavior = view->paintBehavior(); view->setPaintBehavior(oldPaintBehavior | PaintBehaviorFlattenCompositingLayers); PageWidgetDelegate::paint(*m_page, pageOverlays(), canvas, rect, *m_page->deprecatedLocalMainFrame()); view->setPaintBehavior(oldPaintBehavior); } #endif void WebViewImpl::layoutAndPaintAsync(WebLayoutAndPaintAsyncCallback* callback) { m_layerTreeView->layoutAndPaintAsync(callback); } void WebViewImpl::compositeAndReadbackAsync(WebCompositeAndReadbackAsyncCallback* callback) { m_layerTreeView->compositeAndReadbackAsync(callback); } void WebViewImpl::themeChanged() { if (!page()) return; if (!page()->mainFrame()->isLocalFrame()) return; FrameView* view = page()->deprecatedLocalMainFrame()->view(); WebRect damagedRect(0, 0, m_size.width, m_size.height); view->invalidateRect(damagedRect); } void WebViewImpl::enterFullScreenForElement(Element* element) { m_fullscreenController->enterFullScreenForElement(element); } void WebViewImpl::exitFullScreenForElement(Element* element) { m_fullscreenController->exitFullScreenForElement(element); } void WebViewImpl::clearCompositedSelection() { if (m_layerTreeView) m_layerTreeView->clearSelection(); } void WebViewImpl::updateCompositedSelection(const WebSelection& selection) { if (m_layerTreeView) { m_layerTreeView->registerSelection(selection); // TODO(jdduke): Remove this overload when downstream consumers have been updated, crbug.com/466672. m_layerTreeView->registerSelection(selection.start(), selection.end()); } } bool WebViewImpl::hasHorizontalScrollbar() { return mainFrameImpl()->frameView()->horizontalScrollbar(); } bool WebViewImpl::hasVerticalScrollbar() { return mainFrameImpl()->frameView()->verticalScrollbar(); } const WebInputEvent* WebViewImpl::m_currentInputEvent = nullptr; // FIXME: autogenerate this kind of code, and use it throughout Blink rather than // the one-offs for subsets of these values. static String inputTypeToName(WebInputEvent::Type type) { switch (type) { case WebInputEvent::MouseDown: return EventTypeNames::mousedown; case WebInputEvent::MouseUp: return EventTypeNames::mouseup; case WebInputEvent::MouseMove: return EventTypeNames::mousemove; case WebInputEvent::MouseEnter: return EventTypeNames::mouseenter; case WebInputEvent::MouseLeave: return EventTypeNames::mouseleave; case WebInputEvent::ContextMenu: return EventTypeNames::contextmenu; case WebInputEvent::MouseWheel: return EventTypeNames::mousewheel; case WebInputEvent::KeyDown: return EventTypeNames::keydown; case WebInputEvent::KeyUp: return EventTypeNames::keyup; case WebInputEvent::GestureScrollBegin: return EventTypeNames::gesturescrollstart; case WebInputEvent::GestureScrollEnd: return EventTypeNames::gesturescrollend; case WebInputEvent::GestureScrollUpdate: return EventTypeNames::gesturescrollupdate; case WebInputEvent::GestureTapDown: return EventTypeNames::gesturetapdown; case WebInputEvent::GestureShowPress: return EventTypeNames::gestureshowpress; case WebInputEvent::GestureTap: return EventTypeNames::gesturetap; case WebInputEvent::GestureTapUnconfirmed: return EventTypeNames::gesturetapunconfirmed; case WebInputEvent::TouchStart: return EventTypeNames::touchstart; case WebInputEvent::TouchMove: return EventTypeNames::touchmove; case WebInputEvent::TouchEnd: return EventTypeNames::touchend; case WebInputEvent::TouchCancel: return EventTypeNames::touchcancel; default: return String("unknown"); } } void printMsg(WebInputEvent::Type type) { switch (type) { case blink::WebInputEvent::Undefined: OutputDebugStringA("WebViewImpl::handleInputEvent, kUndefined\n"); break; case blink::WebInputEvent::MouseDown: OutputDebugStringA("WebViewImpl::handleInputEvent, kMouseDown\n"); break; case blink::WebInputEvent::MouseUp: OutputDebugStringA("WebViewImpl::handleInputEvent, kMouseUp\n"); break; case blink::WebInputEvent::MouseMove: OutputDebugStringA("WebViewImpl::handleInputEvent, kMouseMove\n"); break; case blink::WebInputEvent::MouseEnter: OutputDebugStringA("WebViewImpl::handleInputEvent, kMouseEnter\n"); break; case blink::WebInputEvent::MouseLeave: OutputDebugStringA("WebViewImpl::handleInputEvent, kMouseLeave\n"); break; case blink::WebInputEvent::ContextMenu: OutputDebugStringA("WebViewImpl::handleInputEvent, kContextMenu\n"); break; case blink::WebInputEvent::MouseWheel: OutputDebugStringA("WebViewImpl::handleInputEvent, kMouseWheel\n"); break; case blink::WebInputEvent::RawKeyDown: OutputDebugStringA("WebViewImpl::handleInputEvent, kRawKeyDown\n"); break; case blink::WebInputEvent::KeyDown: OutputDebugStringA("WebViewImpl::handleInputEvent, kKeyDown\n"); break; case blink::WebInputEvent::KeyUp: OutputDebugStringA("WebViewImpl::handleInputEvent, kKeyUp\n"); break; case blink::WebInputEvent::Char: OutputDebugStringA("WebViewImpl::handleInputEvent, kChar\n"); break; case blink::WebInputEvent::GestureScrollBegin: OutputDebugStringA("WebViewImpl::handleInputEvent, kGestureScrollBegin\n"); break; case blink::WebInputEvent::GestureScrollEnd: OutputDebugStringA("WebViewImpl::handleInputEvent, kGestureScrollEnd\n"); break; case blink::WebInputEvent::GestureScrollUpdate: OutputDebugStringA("WebViewImpl::handleInputEvent, kGestureScrollUpdate\n"); break; case blink::WebInputEvent::GestureFlingStart: OutputDebugStringA("WebViewImpl::handleInputEvent, kGestureFlingStart\n"); break; case blink::WebInputEvent::GestureFlingCancel: OutputDebugStringA("WebViewImpl::handleInputEvent, kGestureFlingCancel\n"); break; case blink::WebInputEvent::GesturePinchBegin: OutputDebugStringA("WebViewImpl::handleInputEvent, kGesturePinchBegin\n"); break; case blink::WebInputEvent::GesturePinchEnd: OutputDebugStringA("WebViewImpl::handleInputEvent, kGesturePinchEnd\n"); break; case blink::WebInputEvent::GesturePinchUpdate: OutputDebugStringA("WebViewImpl::handleInputEvent, kGesturePinchUpdate\n"); break; case blink::WebInputEvent::GestureTapDown: OutputDebugStringA("WebViewImpl::handleInputEvent, kGestureTapDown\n"); break; case blink::WebInputEvent::GestureShowPress: OutputDebugStringA("WebViewImpl::handleInputEvent, kGestureShowPress\n"); break; case blink::WebInputEvent::GestureTap: OutputDebugStringA("WebViewImpl::handleInputEvent, kGestureTap\n"); break; case blink::WebInputEvent::GestureTapCancel: OutputDebugStringA("WebViewImpl::handleInputEvent, kGestureTapCancel\n"); break; case blink::WebInputEvent::GestureLongPress: OutputDebugStringA("WebViewImpl::handleInputEvent, kGestureLongPress\n"); break; case blink::WebInputEvent::GestureLongTap: OutputDebugStringA("WebViewImpl::handleInputEvent, kGestureLongTap\n"); break; case blink::WebInputEvent::GestureTwoFingerTap: OutputDebugStringA("WebViewImpl::handleInputEvent, kGestureTwoFingerTap\n"); break; case blink::WebInputEvent::GestureTapUnconfirmed: OutputDebugStringA("WebViewImpl::handleInputEvent, kGestureTapUnconfirmed\n"); break; case blink::WebInputEvent::GestureDoubleTap: OutputDebugStringA("WebViewImpl::handleInputEvent, kGestureDoubleTap\n"); break; case blink::WebInputEvent::TouchStart: OutputDebugStringA("WebViewImpl::handleInputEvent, kTouchStart\n"); break; case blink::WebInputEvent::TouchMove: OutputDebugStringA("WebViewImpl::handleInputEvent, kTouchMove\n"); break; case blink::WebInputEvent::TouchEnd: OutputDebugStringA("WebViewImpl::handleInputEvent, kTouchEnd\n"); break; case blink::WebInputEvent::TouchCancel: OutputDebugStringA("WebViewImpl::handleInputEvent, kTouchCancel\n"); break; default: break; } } bool WebViewImpl::handleInputEvent(const WebInputEvent& inputEvent) { // TODO(dcheng): The fact that this is getting called when there is no local // main frame is problematic and probably indicates a bug in the input event // routing code. if (!mainFrameImpl()) return false; //printMsg(inputEvent.type); WebAutofillClient* autofillClient = mainFrameImpl()->autofillClient(); UserGestureNotifier notifier(autofillClient, &m_userGestureObserved); // On the first input event since page load, |notifier| instructs the // autofill client to unblock values of password input fields of any forms // on the page. There is a single input event, GestureTap, which can both // be the first event after page load, and cause a form submission. In that // case, the form submission happens before the autofill client is told // to unblock the password values, and so the password values are not // submitted. To avoid that, GestureTap is handled explicitly: if (inputEvent.type == WebInputEvent::GestureTap && autofillClient) { m_userGestureObserved = true; autofillClient->firstUserGestureObserved(); } TRACE_EVENT1("input", "WebViewImpl::handleInputEvent", "type", inputTypeToName(inputEvent.type).ascii()); // If we've started a drag and drop operation, ignore input events until // we're done. if (m_doingDragAndDrop) return true; if (m_devToolsEmulator->handleInputEvent(inputEvent)) return true; WebDevToolsAgentImpl* devTools = mainFrameDevToolsAgentImpl(); if (devTools && devTools->handleInputEvent(inputEvent)) return true; if (m_inspectorOverlay && m_inspectorOverlay->handleInputEvent(inputEvent)) return true; // Report the event to be NOT processed by WebKit, so that the browser can handle it appropriately. if (m_ignoreInputEvents) return false; TemporaryChange<const WebInputEvent*> currentEventChange(m_currentInputEvent, &inputEvent); UIEventWithKeyState::clearNewTabModifierSetFromIsolatedWorld(); if (isPointerLocked() && WebInputEvent::isMouseEventType(inputEvent.type)) { pointerLockMouseEvent(inputEvent); return true; } if (m_mouseCaptureNode && WebInputEvent::isMouseEventType(inputEvent.type)) { TRACE_EVENT1("input", "captured mouse event", "type", inputEvent.type); // Save m_mouseCaptureNode since mouseCaptureLost() will clear it. RefPtrWillBeRawPtr<Node> node = m_mouseCaptureNode; // Not all platforms call mouseCaptureLost() directly. if (inputEvent.type == WebInputEvent::MouseUp) mouseCaptureLost(); OwnPtr<UserGestureIndicator> gestureIndicator; AtomicString eventType; switch (inputEvent.type) { case WebInputEvent::MouseMove: eventType = EventTypeNames::mousemove; break; case WebInputEvent::MouseLeave: eventType = EventTypeNames::mouseout; break; case WebInputEvent::MouseDown: eventType = EventTypeNames::mousedown; gestureIndicator = adoptPtr(new UserGestureIndicator(DefinitelyProcessingNewUserGesture)); m_mouseCaptureGestureToken = gestureIndicator->currentToken(); break; case WebInputEvent::MouseUp: eventType = EventTypeNames::mouseup; gestureIndicator = adoptPtr(new UserGestureIndicator(m_mouseCaptureGestureToken.release())); break; default: ASSERT_NOT_REACHED(); } node->dispatchMouseEvent( PlatformMouseEventBuilder(mainFrameImpl()->frameView(), static_cast<const WebMouseEvent&>(inputEvent)), eventType, static_cast<const WebMouseEvent&>(inputEvent).clickCount); return true; } // FIXME: This should take in the intended frame, not the local frame root. if (PageWidgetDelegate::handleInputEvent(*this, inputEvent, mainFrameImpl()->frame())) return true; // Unhandled touchpad gesture pinch events synthesize mouse wheel events. if (inputEvent.type == WebInputEvent::GesturePinchUpdate) { const WebGestureEvent& pinchEvent = static_cast<const WebGestureEvent&>(inputEvent); // First, synthesize a Windows-like wheel event to send to any handlers that may exist. if (handleSyntheticWheelFromTouchpadPinchEvent(pinchEvent)) return true; if (pinchEvent.data.pinchUpdate.zoomDisabled) return false; if (page()->frameHost().pinchViewport().magnifyScaleAroundAnchor(pinchEvent.data.pinchUpdate.scale, FloatPoint(pinchEvent.x, pinchEvent.y))) return true; } return false; } void WebViewImpl::setCursorVisibilityState(bool isVisible) { if (m_page) m_page->setIsCursorVisible(isVisible); } void WebViewImpl::mouseCaptureLost() { TRACE_EVENT_ASYNC_END0("input", "capturing mouse", this); m_mouseCaptureNode = nullptr; } void WebViewImpl::setFocus(bool enable) { m_page->focusController().setFocused(enable); if (enable) { m_page->focusController().setActive(true); RefPtrWillBeRawPtr<Frame> focusedFrame = m_page->focusController().focusedFrame(); if (focusedFrame && focusedFrame->isLocalFrame()) { LocalFrame* localFrame = toLocalFrame(focusedFrame.get()); Element* element = localFrame->document()->focusedElement(); if (element && localFrame->selection().selection().isNone()) { // If the selection was cleared while the WebView was not // focused, then the focus element shows with a focus ring but // no caret and does respond to keyboard inputs. if (element->isTextFormControl()) { element->updateFocusAppearance(true); } else if (element->isContentEditable()) { // updateFocusAppearance() selects all the text of // contentseditable DIVs. So we set the selection explicitly // instead. Note that this has the side effect of moving the // caret back to the beginning of the text. Position position(element, 0); localFrame->selection().setSelection(VisibleSelection(position, SEL_DEFAULT_AFFINITY)); } } } m_imeAcceptEvents = true; } else { hidePopups(); // Clear focus on the currently focused frame if any. if (!m_page) return; LocalFrame* frame = m_page->mainFrame() && m_page->mainFrame()->isLocalFrame() ? m_page->deprecatedLocalMainFrame() : 0; if (!frame) return; RefPtrWillBeRawPtr<Frame> focusedFrame = m_page->focusController().focusedFrame(); if (focusedFrame && focusedFrame->isLocalFrame()) { // Finish an ongoing composition to delete the composition node. if (toLocalFrame(focusedFrame.get())->inputMethodController().hasComposition()) { WebAutofillClient* autofillClient = WebLocalFrameImpl::fromFrame(toLocalFrame(focusedFrame.get()))->autofillClient(); if (autofillClient) autofillClient->setIgnoreTextChanges(true); toLocalFrame(focusedFrame.get())->inputMethodController().confirmComposition(); if (autofillClient) autofillClient->setIgnoreTextChanges(false); } m_imeAcceptEvents = false; } } } bool WebViewImpl::setComposition( const WebString& text, const WebVector<WebCompositionUnderline>& underlines, int selectionStart, int selectionEnd) { LocalFrame* focused = toLocalFrame(focusedCoreFrame()); if (!focused || !m_imeAcceptEvents) return false; if (WebPlugin* plugin = focusedPluginIfInputMethodSupported(focused)) return plugin->setComposition(text, underlines, selectionStart, selectionEnd); // The input focus has been moved to another WebWidget object. // We should use this |editor| object only to complete the ongoing // composition. InputMethodController& inputMethodController = focused->inputMethodController(); if (!focused->editor().canEdit() && !inputMethodController.hasComposition()) return false; // We should verify the parent node of this IME composition node are // editable because JavaScript may delete a parent node of the composition // node. In this case, WebKit crashes while deleting texts from the parent // node, which doesn't exist any longer. RefPtrWillBeRawPtr<Range> range = inputMethodController.compositionRange(); if (range) { Node* node = range->startContainer(); if (!node || !node->isContentEditable()) return false; } // A keypress event is canceled. If an ongoing composition exists, then the // keydown event should have arisen from a handled key (e.g., backspace). // In this case we ignore the cancellation and continue; otherwise (no // ongoing composition) we exit and signal success only for attempts to // clear the composition. if (m_suppressNextKeypressEvent && !inputMethodController.hasComposition()) return text.isEmpty(); UserGestureIndicator gestureIndicator(DefinitelyProcessingNewUserGesture); // When the range of composition underlines overlap with the range between // selectionStart and selectionEnd, WebKit somehow won't paint the selection // at all (see InlineTextBox::paint() function in InlineTextBox.cpp). // But the selection range actually takes effect. inputMethodController.setComposition(String(text), CompositionUnderlineVectorBuilder(underlines), selectionStart, selectionEnd); return text.isEmpty() || inputMethodController.hasComposition(); } bool WebViewImpl::confirmComposition() { return confirmComposition(DoNotKeepSelection); } bool WebViewImpl::confirmComposition(ConfirmCompositionBehavior selectionBehavior) { return confirmComposition(WebString(), selectionBehavior); } bool WebViewImpl::confirmComposition(const WebString& text) { return confirmComposition(text, DoNotKeepSelection); } bool WebViewImpl::confirmComposition(const WebString& text, ConfirmCompositionBehavior selectionBehavior) { LocalFrame* focused = toLocalFrame(focusedCoreFrame()); if (!focused || !m_imeAcceptEvents) return false; if (WebPlugin* plugin = focusedPluginIfInputMethodSupported(focused)) return plugin->confirmComposition(text, selectionBehavior); return focused->inputMethodController().confirmCompositionOrInsertText(text, selectionBehavior == KeepSelection ? InputMethodController::KeepSelection : InputMethodController::DoNotKeepSelection); } bool WebViewImpl::compositionRange(size_t* location, size_t* length) { // FIXME: Long term, the focused frame should be a local frame. For now, // return early to avoid crashes. Frame* frame = focusedCoreFrame(); if (!frame || frame->isRemoteFrame()) return false; LocalFrame* focused = toLocalFrame(frame); if (!focused || !m_imeAcceptEvents) return false; RefPtrWillBeRawPtr<Range> range = focused->inputMethodController().compositionRange(); if (!range) return false; Element* editable = focused->selection().rootEditableElementOrDocumentElement(); ASSERT(editable); PlainTextRange plainTextRange(PlainTextRange::create(*editable, *range.get())); if (plainTextRange.isNull()) return false; *location = plainTextRange.start(); *length = plainTextRange.length(); return true; } WebTextInputInfo WebViewImpl::textInputInfo() { WebTextInputInfo info; Frame* focusedFrame = focusedCoreFrame(); if (!focusedFrame->isLocalFrame()) return info; LocalFrame* focused = toLocalFrame(focusedFrame); if (!focused) return info; FrameSelection& selection = focused->selection(); Element* element = selection.selection().rootEditableElement(); if (!element) return info; info.inputMode = inputModeOfFocusedElement(); info.type = textInputType(); info.flags = textInputFlags(); if (info.type == WebTextInputTypeNone) return info; if (!focused->editor().canEdit()) return info; // Emits an object replacement character for each replaced element so that // it is exposed to IME and thus could be deleted by IME on android. info.value = plainText(Position(element, PositionAnchorType::BeforeChildren), Position(element, PositionAnchorType::AfterChildren), TextIteratorEmitsObjectReplacementCharacter); if (info.value.isEmpty()) return info; if (RefPtrWillBeRawPtr<Range> range = selection.selection().firstRange()) { PlainTextRange plainTextRange(PlainTextRange::create(*element, *range.get())); if (plainTextRange.isNotNull()) { info.selectionStart = plainTextRange.start(); info.selectionEnd = plainTextRange.end(); } } if (RefPtrWillBeRawPtr<Range> range = focused->inputMethodController().compositionRange()) { PlainTextRange plainTextRange(PlainTextRange::create(*element, *range.get())); if (plainTextRange.isNotNull()) { info.compositionStart = plainTextRange.start(); info.compositionEnd = plainTextRange.end(); } } return info; } WebTextInputType WebViewImpl::textInputType() { Element* element = focusedElement(); if (!element) return WebTextInputTypeNone; if (isHTMLInputElement(*element)) { HTMLInputElement& input = toHTMLInputElement(*element); const AtomicString& type = input.type(); if (input.isDisabledOrReadOnly()) return WebTextInputTypeNone; if (type == InputTypeNames::password) return WebTextInputTypePassword; if (type == InputTypeNames::search) return WebTextInputTypeSearch; if (type == InputTypeNames::email) return WebTextInputTypeEmail; if (type == InputTypeNames::number) return WebTextInputTypeNumber; if (type == InputTypeNames::tel) return WebTextInputTypeTelephone; if (type == InputTypeNames::url) return WebTextInputTypeURL; if (type == InputTypeNames::date) return WebTextInputTypeDate; if (type == InputTypeNames::datetime_local) return WebTextInputTypeDateTimeLocal; if (type == InputTypeNames::month) return WebTextInputTypeMonth; if (type == InputTypeNames::time) return WebTextInputTypeTime; if (type == InputTypeNames::week) return WebTextInputTypeWeek; if (type == InputTypeNames::text) return WebTextInputTypeText; return WebTextInputTypeNone; } if (isHTMLTextAreaElement(*element)) { if (toHTMLTextAreaElement(*element).isDisabledOrReadOnly()) return WebTextInputTypeNone; return WebTextInputTypeTextArea; } #if ENABLE(INPUT_MULTIPLE_FIELDS_UI) if (element->isHTMLElement()) { if (toHTMLElement(element)->isDateTimeFieldElement()) return WebTextInputTypeDateTimeField; } #endif if (element->isContentEditable(Node::UserSelectAllIsAlwaysNonEditable)) return WebTextInputTypeContentEditable; return WebTextInputTypeNone; } int WebViewImpl::textInputFlags() { Element* element = focusedElement(); if (!element) return WebTextInputFlagNone; DEFINE_STATIC_LOCAL(AtomicString, autocompleteString, ("autocomplete", AtomicString::ConstructFromLiteral)); DEFINE_STATIC_LOCAL(AtomicString, autocorrectString, ("autocorrect", AtomicString::ConstructFromLiteral)); int flags = 0; const AtomicString& autocomplete = element->getAttribute(autocompleteString); if (autocomplete == "on") flags |= WebTextInputFlagAutocompleteOn; else if (autocomplete == "off") flags |= WebTextInputFlagAutocompleteOff; const AtomicString& autocorrect = element->getAttribute(autocorrectString); if (autocorrect == "on") flags |= WebTextInputFlagAutocorrectOn; else if (autocorrect == "off") flags |= WebTextInputFlagAutocorrectOff; SpellcheckAttributeState spellcheck = element->spellcheckAttributeState(); if (spellcheck == SpellcheckAttributeTrue) flags |= WebTextInputFlagSpellcheckOn; else if (spellcheck == SpellcheckAttributeFalse) flags |= WebTextInputFlagSpellcheckOff; if (isHTMLTextFormControlElement(element)) { HTMLTextFormControlElement* formElement = static_cast<HTMLTextFormControlElement*>(element); if (formElement->supportsAutocapitalize()) { DEFINE_STATIC_LOCAL(const AtomicString, none, ("none", AtomicString::ConstructFromLiteral)); DEFINE_STATIC_LOCAL(const AtomicString, characters, ("characters", AtomicString::ConstructFromLiteral)); DEFINE_STATIC_LOCAL(const AtomicString, words, ("words", AtomicString::ConstructFromLiteral)); DEFINE_STATIC_LOCAL(const AtomicString, sentences, ("sentences", AtomicString::ConstructFromLiteral)); const AtomicString& autocapitalize = formElement->autocapitalize(); if (autocapitalize == none) flags |= WebTextInputFlagAutocapitalizeNone; else if (autocapitalize == characters) flags |= WebTextInputFlagAutocapitalizeCharacters; else if (autocapitalize == words) flags |= WebTextInputFlagAutocapitalizeWords; else if (autocapitalize == sentences) flags |= WebTextInputFlagAutocapitalizeSentences; else ASSERT_NOT_REACHED(); } } return flags; } WebString WebViewImpl::inputModeOfFocusedElement() { if (!RuntimeEnabledFeatures::inputModeAttributeEnabled()) return WebString(); Element* element = focusedElement(); if (!element) return WebString(); if (isHTMLInputElement(*element)) { const HTMLInputElement& input = toHTMLInputElement(*element); if (input.supportsInputModeAttribute()) return input.fastGetAttribute(HTMLNames::inputmodeAttr).lower(); return WebString(); } if (isHTMLTextAreaElement(*element)) { const HTMLTextAreaElement& textarea = toHTMLTextAreaElement(*element); return textarea.fastGetAttribute(HTMLNames::inputmodeAttr).lower(); } return WebString(); } bool WebViewImpl::selectionBounds(WebRect& anchor, WebRect& focus) const { const Frame* frame = focusedCoreFrame(); if (!frame || !frame->isLocalFrame()) return false; const LocalFrame* localFrame = toLocalFrame(frame); if (!localFrame) return false; FrameSelection& selection = localFrame->selection(); if (selection.isCaret()) { anchor = focus = selection.absoluteCaretBounds(); } else { RefPtrWillBeRawPtr<Range> selectedRange = selection.toNormalizedRange(); if (!selectedRange) return false; RefPtrWillBeRawPtr<Range> range(Range::create(selectedRange->startContainer()->document(), selectedRange->startContainer(), selectedRange->startOffset(), selectedRange->startContainer(), selectedRange->startOffset())); anchor = localFrame->editor().firstRectForRange(range.get()); range = Range::create(selectedRange->endContainer()->document(), selectedRange->endContainer(), selectedRange->endOffset(), selectedRange->endContainer(), selectedRange->endOffset()); focus = localFrame->editor().firstRectForRange(range.get()); } anchor = localFrame->view()->contentsToViewport(anchor); focus = localFrame->view()->contentsToViewport(focus); if (!selection.selection().isBaseFirst()) std::swap(anchor, focus); return true; } WebPlugin* WebViewImpl::focusedPluginIfInputMethodSupported(LocalFrame* frame) { WebPluginContainerImpl* container = WebLocalFrameImpl::pluginContainerFromNode(frame, WebNode(focusedElement())); if (container && container->supportsInputMethod()) return container->plugin(); return 0; } bool WebViewImpl::selectionTextDirection(WebTextDirection& start, WebTextDirection& end) const { const Frame* frame = focusedCoreFrame(); if (!frame || frame->isRemoteFrame()) return false; FrameSelection& selection = toLocalFrame(frame)->selection(); if (!selection.toNormalizedRange()) return false; start = toWebTextDirection(selection.start().primaryDirection()); end = toWebTextDirection(selection.end().primaryDirection()); return true; } bool WebViewImpl::isSelectionAnchorFirst() const { const Frame* frame = focusedCoreFrame(); if (!frame || frame->isRemoteFrame()) return false; return toLocalFrame(frame)->selection().selection().isBaseFirst(); } WebVector<WebCompositionUnderline> WebViewImpl::compositionUnderlines() const { const LocalFrame* focused = toLocalFrame(focusedCoreFrame()); if (!focused) return WebVector<WebCompositionUnderline>(); const Vector<CompositionUnderline>& underlines = focused->inputMethodController().customCompositionUnderlines(); WebVector<WebCompositionUnderline> results(underlines.size()); for (size_t index = 0; index < underlines.size(); ++index) { CompositionUnderline underline = underlines[index]; results[index] = WebCompositionUnderline(underline.startOffset, underline.endOffset, static_cast<WebColor>(underline.color.rgb()), underline.thick, static_cast<WebColor>(underline.backgroundColor.rgb())); } return results; } WebColor WebViewImpl::backgroundColor() const { if (isTransparent()) return Color::transparent; if (!m_page) return m_baseBackgroundColor; if (!m_page->mainFrame()) return m_baseBackgroundColor; if (!m_page->mainFrame()->isLocalFrame()) return m_baseBackgroundColor; FrameView* view = m_page->deprecatedLocalMainFrame()->view(); return view->documentBackgroundColor().rgb(); } WebPagePopup* WebViewImpl::pagePopup() const { return m_pagePopup.get(); } bool WebViewImpl::caretOrSelectionRange(size_t* location, size_t* length) { const LocalFrame* focused = toLocalFrame(focusedCoreFrame()); if (!focused) return false; PlainTextRange selectionOffsets = focused->inputMethodController().getSelectionOffsets(); if (selectionOffsets.isNull()) return false; *location = selectionOffsets.start(); *length = selectionOffsets.length(); return true; } void WebViewImpl::setTextDirection(WebTextDirection direction) { // The Editor::setBaseWritingDirection() function checks if we can change // the text direction of the selected node and updates its DOM "dir" // attribute and its CSS "direction" property. // So, we just call the function as Safari does. const LocalFrame* focused = toLocalFrame(focusedCoreFrame()); if (!focused) return; Editor& editor = focused->editor(); if (!editor.canEdit()) return; switch (direction) { case WebTextDirectionDefault: editor.setBaseWritingDirection(NaturalWritingDirection); break; case WebTextDirectionLeftToRight: editor.setBaseWritingDirection(LeftToRightWritingDirection); break; case WebTextDirectionRightToLeft: editor.setBaseWritingDirection(RightToLeftWritingDirection); break; default: notImplemented(); break; } } bool WebViewImpl::isAcceleratedCompositingActive() const { return m_rootLayer; } void WebViewImpl::willCloseLayerTreeView() { setRootGraphicsLayer(nullptr); m_layerTreeView = 0; } void WebViewImpl::didAcquirePointerLock() { if (page()) page()->pointerLockController().didAcquirePointerLock(); } void WebViewImpl::didNotAcquirePointerLock() { if (page()) page()->pointerLockController().didNotAcquirePointerLock(); } void WebViewImpl::didLosePointerLock() { m_pointerLockGestureToken.clear(); if (page()) page()->pointerLockController().didLosePointerLock(); } void WebViewImpl::didChangeWindowResizerRect() { if (mainFrameImpl()->frameView()) mainFrameImpl()->frameView()->windowResizerRectChanged(); } // WebView your_sha256_hash---- WebSettingsImpl* WebViewImpl::settingsImpl() { if (!m_webSettings) m_webSettings = adoptPtr(new WebSettingsImpl(&m_page->settings(), m_devToolsEmulator.get())); ASSERT(m_webSettings); return m_webSettings.get(); } WebSettings* WebViewImpl::settings() { return settingsImpl(); } WebString WebViewImpl::pageEncoding() const { if (!m_page) return WebString(); if (!m_page->mainFrame()->isLocalFrame()) return WebString(); // FIXME: Is this check needed? if (!m_page->deprecatedLocalMainFrame()->document()->loader()) return WebString(); return m_page->deprecatedLocalMainFrame()->document()->encodingName(); } void WebViewImpl::setPageEncoding(const WebString& encodingName) { if (!m_page) return; // Only change override encoding, don't change default encoding. // Note that the new encoding must be 0 if it isn't supposed to be set. AtomicString newEncodingName; if (!encodingName.isEmpty()) newEncodingName = encodingName; m_page->frameHost().setOverrideEncoding(newEncodingName); if (m_page->mainFrame()->isLocalFrame()) { if (!m_page->deprecatedLocalMainFrame()->loader().currentItem()) return; FrameLoadRequest request = FrameLoadRequest( nullptr, m_page->deprecatedLocalMainFrame()->loader().resourceRequestForReload( FrameLoadTypeReload, KURL(), ClientRedirect)); request.setClientRedirect(ClientRedirect); m_page->deprecatedLocalMainFrame()->loader().load(request, FrameLoadTypeReload); } } WebFrame* WebViewImpl::mainFrame() { return WebFrame::fromFrame(m_page ? m_page->mainFrame() : 0); } WebFrame* WebViewImpl::findFrameByName( const WebString& name, WebFrame* relativeToFrame) { // FIXME: Either this should only deal with WebLocalFrames or it should move to WebFrame. if (!relativeToFrame) relativeToFrame = mainFrame(); Frame* frame = toWebLocalFrameImpl(relativeToFrame)->frame(); frame = frame->tree().find(name); if (!frame || !frame->isLocalFrame()) return 0; return WebLocalFrameImpl::fromFrame(toLocalFrame(frame)); } WebFrame* WebViewImpl::focusedFrame() { return WebFrame::fromFrame(focusedCoreFrame()); } void WebViewImpl::setFocusedFrame(WebFrame* frame) { if (!frame) { // Clears the focused frame if any. Frame* focusedFrame = focusedCoreFrame(); if (focusedFrame && focusedFrame->isLocalFrame()) toLocalFrame(focusedFrame)->selection().setFocused(false); return; } LocalFrame* coreFrame = toWebLocalFrameImpl(frame)->frame(); coreFrame->page()->focusController().setFocusedFrame(coreFrame); } void WebViewImpl::setInitialFocus(bool reverse) { if (!m_page) return; Frame* frame = page()->focusController().focusedOrMainFrame(); if (frame->isLocalFrame()) { if (Document* document = toLocalFrame(frame)->document()) document->setFocusedElement(nullptr); } page()->focusController().setInitialFocus(reverse ? WebFocusTypeBackward : WebFocusTypeForward); } void WebViewImpl::clearFocusedElement() { RefPtrWillBeRawPtr<Frame> frame = focusedCoreFrame(); if (!frame || !frame->isLocalFrame()) return; LocalFrame* localFrame = toLocalFrame(frame.get()); RefPtrWillBeRawPtr<Document> document = localFrame->document(); if (!document) return; RefPtrWillBeRawPtr<Element> oldFocusedElement = document->focusedElement(); // Clear the focused node. document->setFocusedElement(nullptr); if (!oldFocusedElement) return; // If a text field has focus, we need to make sure the selection controller // knows to remove selection from it. Otherwise, the text field is still // processing keyboard events even though focus has been moved to the page and // keystrokes get eaten as a result. if (oldFocusedElement->isContentEditable() || oldFocusedElement->isTextFormControl()) localFrame->selection().clear(); } bool WebViewImpl::scrollFocusedNodeIntoRect(const WebRect& rectInViewport) { LocalFrame* frame = page()->mainFrame() && page()->mainFrame()->isLocalFrame() ? page()->deprecatedLocalMainFrame() : 0; Element* element = focusedElement(); if (!frame || !frame->view() || !element) return false; bool zoomInToLegibleScale = m_webSettings->autoZoomFocusedNodeToLegibleScale() && !shouldDisableDesktopWorkarounds(); float scale; IntPoint scroll; bool needAnimation; computeScaleAndScrollForFocusedNode(element, zoomInToLegibleScale, scale, scroll, needAnimation); if (needAnimation) return startPageScaleAnimation(scroll, false, scale, scrollAndScaleAnimationDurationInSeconds); return false; } void WebViewImpl::computeScaleAndScrollForFocusedNode(Node* focusedNode, bool zoomInToLegibleScale, float& newScale, IntPoint& newScroll, bool& needAnimation) { focusedNode->document().updateLayoutIgnorePendingStylesheets(); PinchViewport& pinchViewport = page()->frameHost().pinchViewport(); WebRect caretInViewport, unusedEnd; selectionBounds(caretInViewport, unusedEnd); // 'caretInDocument' is rect encompassing the blinking cursor relative to the root document. IntRect caretInDocument = mainFrameImpl()->frameView()->frameToContents(pinchViewport.viewportToRootFrame(caretInViewport)); IntRect textboxRectInDocument = mainFrameImpl()->frameView()->frameToContents( focusedNode->document().view()->contentsToRootFrame(pixelSnappedIntRect(focusedNode->Node::boundingBox()))); if (!zoomInToLegibleScale) { newScale = pageScaleFactor(); } else { // Pick a scale which is reasonably readable. This is the scale at which // the caret height will become minReadableCaretHeightForNode (adjusted // for dpi and font scale factor). const int minReadableCaretHeightForNode = textboxRectInDocument.height() >= 2 * caretInDocument.height() ? minReadableCaretHeightForTextArea : minReadableCaretHeight; newScale = clampPageScaleFactorToLimits(maximumLegiblePageScale() * minReadableCaretHeightForNode / caretInDocument.height()); newScale = std::max(newScale, pageScaleFactor()); } const float deltaScale = newScale / pageScaleFactor(); needAnimation = false; // If we are at less than the target zoom level, zoom in. if (deltaScale > minScaleChangeToTriggerZoom) needAnimation = true; else newScale = pageScaleFactor(); // If the caret is offscreen, then animate. if (!pinchViewport.visibleRectInDocument().contains(caretInDocument)) needAnimation = true; // If the box is partially offscreen and it's possible to bring it fully // onscreen, then animate. if (pinchViewport.visibleRect().width() >= textboxRectInDocument.width() && pinchViewport.visibleRect().height() >= textboxRectInDocument.height() && !pinchViewport.visibleRectInDocument().contains(textboxRectInDocument)) needAnimation = true; if (!needAnimation) return; FloatSize targetViewportSize = pinchViewport.size(); targetViewportSize.scale(1 / newScale); if (textboxRectInDocument.width() <= targetViewportSize.width()) { // Field is narrower than screen. Try to leave padding on left so field's // label is visible, but it's more important to ensure entire field is // onscreen. int idealLeftPadding = targetViewportSize.width() * leftBoxRatio; int maxLeftPaddingKeepingBoxOnscreen = targetViewportSize.width() - textboxRectInDocument.width(); newScroll.setX(textboxRectInDocument.x() - std::min<int>(idealLeftPadding, maxLeftPaddingKeepingBoxOnscreen)); } else { // Field is wider than screen. Try to left-align field, unless caret would // be offscreen, in which case right-align the caret. newScroll.setX(std::max<int>(textboxRectInDocument.x(), caretInDocument.x() + caretInDocument.width() + caretPadding - targetViewportSize.width())); } if (textboxRectInDocument.height() <= targetViewportSize.height()) { // Field is shorter than screen. Vertically center it. newScroll.setY(textboxRectInDocument.y() - (targetViewportSize.height() - textboxRectInDocument.height()) / 2); } else { // Field is taller than screen. Try to top align field, unless caret would // be offscreen, in which case bottom-align the caret. newScroll.setY(std::max<int>(textboxRectInDocument.y(), caretInDocument.y() + caretInDocument.height() + caretPadding - targetViewportSize.height())); } } void WebViewImpl::advanceFocus(bool reverse) { page()->focusController().advanceFocus(reverse ? WebFocusTypeBackward : WebFocusTypeForward); } double WebViewImpl::zoomLevel() { return m_zoomLevel; } double WebViewImpl::setZoomLevel(double zoomLevel) { if (zoomLevel < m_minimumZoomLevel) m_zoomLevel = m_minimumZoomLevel; else if (zoomLevel > m_maximumZoomLevel) m_zoomLevel = m_maximumZoomLevel; else m_zoomLevel = zoomLevel; LocalFrame* frame = mainFrameImpl()->frame(); WebPluginContainerImpl* pluginContainer = WebLocalFrameImpl::pluginContainerFromFrame(frame); if (pluginContainer) pluginContainer->plugin()->setZoomLevel(m_zoomLevel, false); else { float zoomFactor = m_zoomFactorOverride ? m_zoomFactorOverride : static_cast<float>(zoomLevelToZoomFactor(m_zoomLevel)); frame->setPageZoomFactor(zoomFactor); } return m_zoomLevel; } void WebViewImpl::zoomLimitsChanged(double minimumZoomLevel, double maximumZoomLevel) { m_minimumZoomLevel = minimumZoomLevel; m_maximumZoomLevel = maximumZoomLevel; m_client->zoomLimitsChanged(m_minimumZoomLevel, m_maximumZoomLevel); } float WebViewImpl::textZoomFactor() { return mainFrameImpl()->frame()->textZoomFactor(); } float WebViewImpl::setTextZoomFactor(float textZoomFactor) { LocalFrame* frame = mainFrameImpl()->frame(); if (WebLocalFrameImpl::pluginContainerFromFrame(frame)) return 1; frame->setTextZoomFactor(textZoomFactor); return textZoomFactor; } void WebViewImpl::fullFramePluginZoomLevelChanged(double zoomLevel) { if (zoomLevel == m_zoomLevel) return; m_zoomLevel = std::max(std::min(zoomLevel, m_maximumZoomLevel), m_minimumZoomLevel); m_client->zoomLevelChanged(); } double WebView::zoomLevelToZoomFactor(double zoomLevel) { return pow(textSizeMultiplierRatio, zoomLevel); } double WebView::zoomFactorToZoomLevel(double factor) { // Since factor = 1.2^level, level = log(factor) / log(1.2) return log(factor) / log(textSizeMultiplierRatio); } float WebViewImpl::pageScaleFactor() const { if (!page()) return 1; return page()->frameHost().pinchViewport().scale(); } float WebViewImpl::clampPageScaleFactorToLimits(float scaleFactor) const { return pageScaleConstraintsSet().finalConstraints().clampToConstraints(scaleFactor); } void WebViewImpl::setPinchViewportOffset(const WebFloatPoint& offset) { ASSERT(page()); page()->frameHost().pinchViewport().setLocation(offset); } WebFloatPoint WebViewImpl::pinchViewportOffset() const { ASSERT(page()); return page()->frameHost().pinchViewport().visibleRect().location(); } void WebViewImpl::scrollAndRescaleViewports(float scaleFactor, const IntPoint& mainFrameOrigin, const FloatPoint& pinchViewportOrigin) { if (!page()) return; if (!mainFrameImpl()) return; FrameView * view = mainFrameImpl()->frameView(); if (!view) return; // Order is important: pinch viewport location is clamped based on // main frame scroll position and pinch viewport scale. view->setScrollPosition(mainFrameOrigin, ProgrammaticScroll); setPageScaleFactor(scaleFactor); page()->frameHost().pinchViewport().setLocation(pinchViewportOrigin); } void WebViewImpl::setPageScaleFactorAndLocation(float scaleFactor, const FloatPoint& location) { ASSERT(page()); page()->frameHost().pinchViewport().setScaleAndLocation( clampPageScaleFactorToLimits(scaleFactor), location); } void WebViewImpl::setPageScaleFactor(float scaleFactor) { ASSERT(page()); scaleFactor = clampPageScaleFactorToLimits(scaleFactor); if (scaleFactor == pageScaleFactor()) return; page()->frameHost().pinchViewport().setScale(scaleFactor); } float WebViewImpl::deviceScaleFactor() const { if (!page()) return 1; return page()->deviceScaleFactor(); } void WebViewImpl::setDeviceScaleFactor(float scaleFactor) { if (!page()) return; page()->setDeviceScaleFactor(scaleFactor); if (m_layerTreeView) updateLayerTreeDeviceScaleFactor(); } void WebViewImpl::setDeviceColorProfile(const WebVector<char>& colorProfile) { if (!page()) return; Vector<char> deviceProfile; deviceProfile.append(colorProfile.data(), colorProfile.size()); page()->setDeviceColorProfile(deviceProfile); } void WebViewImpl::resetDeviceColorProfile() { if (!page()) return; page()->resetDeviceColorProfile(); } void WebViewImpl::enableAutoResizeMode(const WebSize& minSize, const WebSize& maxSize) { m_shouldAutoResize = true; m_minAutoSize = minSize; m_maxAutoSize = maxSize; configureAutoResizeMode(); } void WebViewImpl::disableAutoResizeMode() { m_shouldAutoResize = false; configureAutoResizeMode(); } void WebViewImpl::setDefaultPageScaleLimits(float minScale, float maxScale) { return page()->frameHost().setDefaultPageScaleLimits(minScale, maxScale); } void WebViewImpl::setInitialPageScaleOverride(float initialPageScaleFactorOverride) { PageScaleConstraints constraints = pageScaleConstraintsSet().userAgentConstraints(); constraints.initialScale = initialPageScaleFactorOverride; if (constraints == pageScaleConstraintsSet().userAgentConstraints()) return; pageScaleConstraintsSet().setNeedsReset(true); page()->frameHost().setUserAgentPageScaleConstraints(constraints); } void WebViewImpl::setMaximumLegibleScale(float maximumLegibleScale) { m_maximumLegibleScale = maximumLegibleScale; } void WebViewImpl::setIgnoreViewportTagScaleLimits(bool ignore) { PageScaleConstraints constraints = pageScaleConstraintsSet().userAgentConstraints(); if (ignore) { constraints.minimumScale = pageScaleConstraintsSet().defaultConstraints().minimumScale; constraints.maximumScale = pageScaleConstraintsSet().defaultConstraints().maximumScale; } else { constraints.minimumScale = -1; constraints.maximumScale = -1; } page()->frameHost().setUserAgentPageScaleConstraints(constraints); } IntSize WebViewImpl::mainFrameSize() { return pageScaleConstraintsSet().mainFrameSize(); } PageScaleConstraintsSet& WebViewImpl::pageScaleConstraintsSet() const { return page()->frameHost().pageScaleConstraintsSet(); } void WebViewImpl::refreshPageScaleFactorAfterLayout() { if (!mainFrame() || !page() || !page()->mainFrame() || !page()->mainFrame()->isLocalFrame() || !page()->deprecatedLocalMainFrame()->view()) return; FrameView* view = page()->deprecatedLocalMainFrame()->view(); updatePageDefinedViewportConstraints(mainFrameImpl()->frame()->document()->viewportDescription()); pageScaleConstraintsSet().computeFinalConstraints(); int verticalScrollbarWidth = 0; if (view->verticalScrollbar() && !view->verticalScrollbar()->isOverlayScrollbar()) verticalScrollbarWidth = view->verticalScrollbar()->width(); pageScaleConstraintsSet().adjustFinalConstraintsToContentsSize(contentsSize(), verticalScrollbarWidth, settings()->shrinksViewportContentToFit()); float newPageScaleFactor = pageScaleFactor(); if (pageScaleConstraintsSet().needsReset() && pageScaleConstraintsSet().finalConstraints().initialScale != -1) { newPageScaleFactor = pageScaleConstraintsSet().finalConstraints().initialScale; pageScaleConstraintsSet().setNeedsReset(false); } setPageScaleFactor(newPageScaleFactor); updateLayerTreeViewport(); } void WebViewImpl::updatePageDefinedViewportConstraints(const ViewportDescription& description) { // If we're not reading the viewport meta tag, allow GPU rasterization. if (!settingsImpl()->viewportMetaEnabled()) { m_matchesHeuristicsForGpuRasterization = true; if (m_layerTreeView) m_layerTreeView->heuristicsForGpuRasterizationUpdated(m_matchesHeuristicsForGpuRasterization); } if (!settings()->viewportEnabled() || !page() || (!m_size.width && !m_size.height) || !page()->mainFrame()->isLocalFrame()) return; Document* document = page()->deprecatedLocalMainFrame()->document(); m_matchesHeuristicsForGpuRasterization = description.matchesHeuristicsForGpuRasterization(); if (m_layerTreeView) m_layerTreeView->heuristicsForGpuRasterizationUpdated(m_matchesHeuristicsForGpuRasterization); Length defaultMinWidth = document->viewportDefaultMinWidth(); if (defaultMinWidth.isAuto()) defaultMinWidth = Length(ExtendToZoom); ViewportDescription adjustedDescription = description; if (settingsImpl()->viewportMetaLayoutSizeQuirk() && adjustedDescription.type == ViewportDescription::ViewportMeta) { const int legacyWidthSnappingMagicNumber = 320; if (adjustedDescription.maxWidth.isFixed() && adjustedDescription.maxWidth.value() <= legacyWidthSnappingMagicNumber) adjustedDescription.maxWidth = Length(DeviceWidth); if (adjustedDescription.maxHeight.isFixed() && adjustedDescription.maxHeight.value() <= m_size.height) adjustedDescription.maxHeight = Length(DeviceHeight); adjustedDescription.minWidth = adjustedDescription.maxWidth; adjustedDescription.minHeight = adjustedDescription.maxHeight; } float oldInitialScale = pageScaleConstraintsSet().pageDefinedConstraints().initialScale; pageScaleConstraintsSet().updatePageDefinedConstraints(adjustedDescription, defaultMinWidth); if (settingsImpl()->clobberUserAgentInitialScaleQuirk() && pageScaleConstraintsSet().userAgentConstraints().initialScale != -1 && pageScaleConstraintsSet().userAgentConstraints().initialScale * deviceScaleFactor() <= 1) { if (description.maxWidth == Length(DeviceWidth) || (description.maxWidth.type() == Auto && pageScaleConstraintsSet().pageDefinedConstraints().initialScale == 1.0f)) setInitialPageScaleOverride(-1); } pageScaleConstraintsSet().adjustForAndroidWebViewQuirks(adjustedDescription, defaultMinWidth.intValue(), deviceScaleFactor(), settingsImpl()->supportDeprecatedTargetDensityDPI(), page()->settings().wideViewportQuirkEnabled(), page()->settings().useWideViewport(), page()->settings().loadWithOverviewMode(), settingsImpl()->viewportMetaNonUserScalableQuirk()); float newInitialScale = pageScaleConstraintsSet().pageDefinedConstraints().initialScale; if (oldInitialScale != newInitialScale && newInitialScale != -1) { pageScaleConstraintsSet().setNeedsReset(true); if (mainFrameImpl() && mainFrameImpl()->frameView()) mainFrameImpl()->frameView()->setNeedsLayout(); } updateMainFrameLayoutSize(); if (LocalFrame* frame = page()->deprecatedLocalMainFrame()) { if (TextAutosizer* textAutosizer = frame->document()->textAutosizer()) textAutosizer->updatePageInfoInAllFrames(); } } void WebViewImpl::updateMainFrameLayoutSize() { if (m_shouldAutoResize || !mainFrameImpl()) return; RefPtrWillBeRawPtr<FrameView> view = mainFrameImpl()->frameView(); if (!view) return; WebSize layoutSize = m_size; if (settings()->viewportEnabled()) layoutSize = pageScaleConstraintsSet().layoutSize(); if (page()->settings().forceZeroLayoutHeight()) layoutSize.height = 0; view->setLayoutSize(layoutSize); // Resizing marks the frame as needsLayout. Inform clients so that they // will perform the layout. Widgets held by WebPluginContainerImpl do not otherwise // see this resize layout invalidation. if (client()) client()->didUpdateLayoutSize(layoutSize); } IntSize WebViewImpl::contentsSize() const { if (!page()->mainFrame()->isLocalFrame()) return IntSize(); LayoutView* root = page()->deprecatedLocalMainFrame()->contentLayoutObject(); if (!root) return IntSize(); return root->documentRect().size(); } WebSize WebViewImpl::contentsPreferredMinimumSize() { Document* document = m_page->mainFrame()->isLocalFrame() ? m_page->deprecatedLocalMainFrame()->document() : 0; if (!document || !document->layoutView() || !document->documentElement()) return WebSize(); layout(); int widthScaled = document->layoutView()->minPreferredLogicalWidth().round(); // Already accounts for zoom. int heightScaled = static_cast<int>((document->documentElement()->scrollHeight() * zoomLevelToZoomFactor(zoomLevel())) + 0.5); // +0.5 to round rather than truncating return IntSize(widthScaled, heightScaled); } void WebViewImpl::enableViewport() { settings()->setViewportEnabled(true); } void WebViewImpl::disableViewport() { settings()->setViewportEnabled(false); pageScaleConstraintsSet().clearPageDefinedConstraints(); updateMainFrameLayoutSize(); } float WebViewImpl::defaultMinimumPageScaleFactor() const { return pageScaleConstraintsSet().defaultConstraints().minimumScale; } float WebViewImpl::defaultMaximumPageScaleFactor() const { return pageScaleConstraintsSet().defaultConstraints().maximumScale; } float WebViewImpl::minimumPageScaleFactor() const { return pageScaleConstraintsSet().finalConstraints().minimumScale; } float WebViewImpl::maximumPageScaleFactor() const { return pageScaleConstraintsSet().finalConstraints().maximumScale; } void WebViewImpl::resetScrollAndScaleState() { page()->frameHost().pinchViewport().reset(); if (!page()->mainFrame()->isLocalFrame()) return; if (FrameView* frameView = toLocalFrame(page()->mainFrame())->view()) { ScrollableArea* scrollableArea = frameView->layoutViewportScrollableArea(); if (scrollableArea->scrollPositionDouble() != DoublePoint::zero()) scrollableArea->setScrollPosition(DoublePoint::zero(), ProgrammaticScroll); } pageScaleConstraintsSet().setNeedsReset(true); // Clobber saved scales and scroll offsets. if (FrameView* view = page()->deprecatedLocalMainFrame()->document()->view()) view->cacheCurrentScrollPosition(); } void WebViewImpl::performMediaPlayerAction(const WebMediaPlayerAction& action, const WebPoint& location) { HitTestResult result = hitTestResultForViewportPos(location); RefPtrWillBeRawPtr<Node> node = result.innerNode(); if (!isHTMLVideoElement(*node) && !isHTMLAudioElement(*node)) return; RefPtrWillBeRawPtr<HTMLMediaElement> mediaElement = static_pointer_cast<HTMLMediaElement>(node); switch (action.type) { case WebMediaPlayerAction::Play: if (action.enable) mediaElement->play(); else mediaElement->pause(); break; case WebMediaPlayerAction::Mute: mediaElement->setMuted(action.enable); break; case WebMediaPlayerAction::Loop: mediaElement->setLoop(action.enable); break; case WebMediaPlayerAction::Controls: mediaElement->setBooleanAttribute(HTMLNames::controlsAttr, action.enable); break; default: ASSERT_NOT_REACHED(); } } void WebViewImpl::performPluginAction(const WebPluginAction& action, const WebPoint& location) { // FIXME: Location is probably in viewport coordinates HitTestResult result = hitTestResultForRootFramePos(location); RefPtrWillBeRawPtr<Node> node = result.innerNode(); if (!isHTMLObjectElement(*node) && !isHTMLEmbedElement(*node)) return; LayoutObject* object = node->layoutObject(); if (object && object->isLayoutPart()) { Widget* widget = toLayoutPart(object)->widget(); if (widget && widget->isPluginContainer()) { WebPluginContainerImpl* plugin = toWebPluginContainerImpl(widget); switch (action.type) { case WebPluginAction::Rotate90Clockwise: plugin->plugin()->rotateView(WebPlugin::RotationType90Clockwise); break; case WebPluginAction::Rotate90Counterclockwise: plugin->plugin()->rotateView(WebPlugin::RotationType90Counterclockwise); break; default: ASSERT_NOT_REACHED(); } } } } WebHitTestResult WebViewImpl::hitTestResultAt(const WebPoint& point) { return coreHitTestResultAt(point); } HitTestResult WebViewImpl::coreHitTestResultAt(const WebPoint& pointInViewport) { FrameView* view = mainFrameImpl()->frameView(); IntPoint pointInRootFrame = view->contentsToFrame(view->viewportToContents(pointInViewport)); return hitTestResultForRootFramePos(pointInRootFrame); } void WebViewImpl::copyImageAt(const WebPoint& point) { if (!m_page) return; HitTestResult result = hitTestResultForViewportPos(point); if (!isHTMLCanvasElement(result.innerNodeOrImageMapImage()) && result.absoluteImageURL().isEmpty()) { // There isn't actually an image at these coordinates. Might be because // the window scrolled while the context menu was open or because the page // changed itself between when we thought there was an image here and when // we actually tried to retreive the image. // // FIXME: implement a cache of the most recent HitTestResult to avoid having // to do two hit tests. return; } m_page->deprecatedLocalMainFrame()->editor().copyImage(result); } void WebViewImpl::saveImageAt(const WebPoint& point) { if (!m_client) return; Node* node = hitTestResultForViewportPos(point).innerNodeOrImageMapImage(); if (!node || !(isHTMLCanvasElement(*node) || isHTMLImageElement(*node))) return; String url = toElement(*node).imageSourceURL(); if (!KURL(KURL(), url).protocolIsData()) return; m_client->saveImageFromDataURL(url); } void WebViewImpl::dragSourceEndedAt( const WebPoint& clientPoint, const WebPoint& screenPoint, WebDragOperation operation) { PlatformMouseEvent pme(clientPoint, screenPoint, LeftButton, PlatformEvent::MouseMoved, 0, false, false, false, false, PlatformMouseEvent::RealOrIndistinguishable, 0); m_page->deprecatedLocalMainFrame()->eventHandler().dragSourceEndedAt(pme, static_cast<DragOperation>(operation)); } void WebViewImpl::dragSourceSystemDragEnded() { // It's possible for us to get this callback while not doing a drag if // it's from a previous page that got unloaded. if (m_doingDragAndDrop) { m_page->dragController().dragEnded(); m_doingDragAndDrop = false; } } WebDragOperation WebViewImpl::dragTargetDragEnter( const WebDragData& webDragData, const WebPoint& clientPoint, const WebPoint& screenPoint, WebDragOperationsMask operationsAllowed, int modifiers) { ASSERT(!m_currentDragData); m_currentDragData = DataObject::create(webDragData); m_operationsAllowed = operationsAllowed; return dragTargetDragEnterOrOver(clientPoint, screenPoint, DragEnter, modifiers); } WebDragOperation WebViewImpl::dragTargetDragOver( const WebPoint& clientPoint, const WebPoint& screenPoint, WebDragOperationsMask operationsAllowed, int modifiers) { m_operationsAllowed = operationsAllowed; return dragTargetDragEnterOrOver(clientPoint, screenPoint, DragOver, modifiers); } void WebViewImpl::dragTargetDragLeave() { ASSERT(m_currentDragData); DragData dragData( m_currentDragData.get(), IntPoint(), IntPoint(), static_cast<DragOperation>(m_operationsAllowed)); m_page->dragController().dragExited(&dragData); // FIXME: why is the drag scroll timer not stopped here? m_dragOperation = WebDragOperationNone; m_currentDragData = nullptr; } void WebViewImpl::dragTargetDrop(const WebPoint& clientPoint, const WebPoint& screenPoint, int modifiers) { ASSERT(m_currentDragData); WebAutofillClient* autofillClient = mainFrameImpl() ? mainFrameImpl()->autofillClient() : 0; UserGestureNotifier notifier(autofillClient, &m_userGestureObserved); // If this webview transitions from the "drop accepting" state to the "not // accepting" state, then our IPC message reply indicating that may be in- // flight, or else delayed by javascript processing in this webview. If a // drop happens before our IPC reply has reached the browser process, then // the browser forwards the drop to this webview. So only allow a drop to // proceed if our webview m_dragOperation state is not DragOperationNone. if (m_dragOperation == WebDragOperationNone) { // IPC RACE CONDITION: do not allow this drop. dragTargetDragLeave(); return; } m_currentDragData->setModifiers(toPlatformMouseEventModifiers(modifiers)); DragData dragData( m_currentDragData.get(), clientPoint, screenPoint, static_cast<DragOperation>(m_operationsAllowed)); UserGestureIndicator gesture(DefinitelyProcessingNewUserGesture); m_page->dragController().performDrag(&dragData); m_dragOperation = WebDragOperationNone; m_currentDragData = nullptr; } void WebViewImpl::spellingMarkers(WebVector<uint32_t>* markers) { Vector<uint32_t> result; for (Frame* frame = m_page->mainFrame(); frame; frame = frame->tree().traverseNext()) { if (!frame->isLocalFrame()) continue; const DocumentMarkerVector& documentMarkers = toLocalFrame(frame)->document()->markers().markers(); for (size_t i = 0; i < documentMarkers.size(); ++i) result.append(documentMarkers[i]->hash()); } markers->assign(result); } void WebViewImpl::removeSpellingMarkersUnderWords(const WebVector<WebString>& words) { Vector<String> convertedWords; convertedWords.append(words.data(), words.size()); for (Frame* frame = m_page->mainFrame(); frame; frame = frame->tree().traverseNext()) { if (frame->isLocalFrame()) toLocalFrame(frame)->removeSpellingMarkersUnderWords(convertedWords); } } WebDragOperation WebViewImpl::dragTargetDragEnterOrOver(const WebPoint& clientPoint, const WebPoint& screenPoint, DragAction dragAction, int modifiers) { ASSERT(m_currentDragData); m_currentDragData->setModifiers(toPlatformMouseEventModifiers(modifiers)); DragData dragData( m_currentDragData.get(), clientPoint, screenPoint, static_cast<DragOperation>(m_operationsAllowed)); DragSession dragSession; if (dragAction == DragEnter) dragSession = m_page->dragController().dragEntered(&dragData); else dragSession = m_page->dragController().dragUpdated(&dragData); DragOperation dropEffect = dragSession.operation; // Mask the drop effect operation against the drag source's allowed operations. if (!(dropEffect & dragData.draggingSourceOperationMask())) dropEffect = DragOperationNone; m_dragOperation = static_cast<WebDragOperation>(dropEffect); return m_dragOperation; } void WebViewImpl::sendResizeEventAndRepaint() { // FIXME: This is wrong. The FrameView is responsible sending a resizeEvent // as part of layout. Layout is also responsible for sending invalidations // to the embedder. This method and all callers may be wrong. -- eseidel. if (mainFrameImpl()->frameView()) { // Enqueues the resize event. mainFrameImpl()->frame()->document()->enqueueResizeEvent(); } if (m_client) { if (m_layerTreeView) { updateLayerTreeViewport(); } else { WebRect damagedRect(0, 0, m_size.width, m_size.height); m_client->didInvalidateRect(damagedRect); } } if (m_pageOverlays) m_pageOverlays->update(); m_devToolsEmulator->viewportChanged(); } void WebViewImpl::configureAutoResizeMode() { if (!mainFrameImpl() || !mainFrameImpl()->frame() || !mainFrameImpl()->frame()->view()) return; if (m_shouldAutoResize) mainFrameImpl()->frame()->view()->enableAutoSizeMode(m_minAutoSize, m_maxAutoSize); else mainFrameImpl()->frame()->view()->disableAutoSizeMode(); } unsigned long WebViewImpl::createUniqueIdentifierForRequest() { return createUniqueIdentifier(); } void WebViewImpl::setCompositorDeviceScaleFactorOverride(float deviceScaleFactor) { if (m_compositorDeviceScaleFactorOverride == deviceScaleFactor) return; m_compositorDeviceScaleFactorOverride = deviceScaleFactor; if (page() && m_layerTreeView) updateLayerTreeDeviceScaleFactor(); } void WebViewImpl::setRootLayerTransform(const WebSize& rootLayerOffset, float rootLayerScale) { if (m_rootLayerScale == rootLayerScale && m_rootLayerOffset == rootLayerOffset) return; m_rootLayerScale = rootLayerScale; m_rootLayerOffset = rootLayerOffset; if (mainFrameImpl()) mainFrameImpl()->setInputEventsTransformForEmulation(m_rootLayerOffset, m_rootLayerScale); updateRootLayerTransform(); } void WebViewImpl::enableDeviceEmulation(const WebDeviceEmulationParams& params) { m_devToolsEmulator->enableDeviceEmulation(params); } void WebViewImpl::disableDeviceEmulation() { m_devToolsEmulator->disableDeviceEmulation(); } #ifdef MINIBLINK_NOT_IMPLEMENTED WebAXObject WebViewImpl::accessibilityObject() { if (!mainFrameImpl()) return WebAXObject(); Document* document = mainFrameImpl()->frame()->document(); return WebAXObject(toAXObjectCacheImpl(document->axObjectCache())->root()); } #endif // MINIBLINK_NOT_IMPLEMENTED void WebViewImpl::performCustomContextMenuAction(unsigned action) { if (!m_page) return; ContextMenu* menu = m_page->contextMenuController().contextMenu(); if (!menu) return; const ContextMenuItem* item = menu->itemWithAction(static_cast<ContextMenuAction>(ContextMenuItemBaseCustomTag + action)); if (item) m_page->contextMenuController().contextMenuItemSelected(item); m_page->contextMenuController().clearContextMenu(); } void WebViewImpl::showContextMenu() { if (!page()) return; page()->contextMenuController().clearContextMenu(); m_contextMenuAllowed = true; if (LocalFrame* focusedFrame = toLocalFrame(page()->focusController().focusedOrMainFrame())) focusedFrame->eventHandler().sendContextMenuEventForKey(nullptr); m_contextMenuAllowed = false; } void WebViewImpl::extractSmartClipData(WebRect rectInViewport, WebString& clipText, WebString& clipHtml, WebRect& clipRectInViewport) { LocalFrame* localFrame = toLocalFrame(focusedCoreFrame()); if (!localFrame) return; SmartClipData clipData = SmartClip(localFrame).dataForRect(rectInViewport); clipText = clipData.clipData(); clipRectInViewport = clipData.rectInViewport(); WebLocalFrameImpl* frame = mainFrameImpl(); if (!frame) return; WebPoint startPoint(rectInViewport.x, rectInViewport.y); WebPoint endPoint(rectInViewport.x + rectInViewport.width, rectInViewport.y + rectInViewport.height); VisiblePosition startVisiblePosition = frame->visiblePositionForViewportPoint(startPoint); VisiblePosition endVisiblePosition = frame->visiblePositionForViewportPoint(endPoint); Position startPosition = startVisiblePosition.deepEquivalent(); Position endPosition = endVisiblePosition.deepEquivalent(); // document() will return null if -webkit-user-select is set to none. if (!startPosition.document() || !endPosition.document()) return; clipHtml = createMarkup(startPosition, endPosition, AnnotateForInterchange, ConvertBlocksToInlines::NotConvert, ResolveNonLocalURLs); } void WebViewImpl::hidePopups() { cancelPagePopup(); } void WebViewImpl::setIsTransparent(bool isTransparent) { // Set any existing frames to be transparent. Frame* frame = m_page->mainFrame(); while (frame) { if (frame->isLocalFrame()) toLocalFrame(frame)->view()->setTransparent(isTransparent); frame = frame->tree().traverseNext(); } // Future frames check this to know whether to be transparent. m_isTransparent = isTransparent; if (m_layerTreeView) m_layerTreeView->setHasTransparentBackground(this->isTransparent()); } bool WebViewImpl::isTransparent() const { return m_isTransparent; } void WebViewImpl::setBaseBackgroundColor(WebColor color) { layout(); if (m_baseBackgroundColor == color) return; m_baseBackgroundColor = color; if (m_page->mainFrame() && m_page->mainFrame()->isLocalFrame()) m_page->deprecatedLocalMainFrame()->view()->setBaseBackgroundColor(color); updateLayerTreeBackgroundColor(); } void WebViewImpl::setIsActive(bool active) { if (page()) page()->focusController().setActive(active); } bool WebViewImpl::isActive() const { return page() ? page()->focusController().isActive() : false; } void WebViewImpl::setDomainRelaxationForbidden(bool forbidden, const WebString& scheme) { SchemeRegistry::setDomainRelaxationForbiddenForURLScheme(forbidden, String(scheme)); } void WebViewImpl::setWindowFeatures(const WebWindowFeatures& features) { m_page->chromeClient().setWindowFeatures(features); } void WebViewImpl::setOpenedByDOM() { m_page->setOpenedByDOM(); } void WebViewImpl::setSelectionColors(unsigned activeBackgroundColor, unsigned activeForegroundColor, unsigned inactiveBackgroundColor, unsigned inactiveForegroundColor) { #if USE(DEFAULT_RENDER_THEME) LayoutThemeDefault::setSelectionColors(activeBackgroundColor, activeForegroundColor, inactiveBackgroundColor, inactiveForegroundColor); LayoutTheme::theme().platformColorsDidChange(); #endif } void WebViewImpl::didCommitLoad(bool isNewNavigation, bool isNavigationWithinPage) { if (isNewNavigation && !isNavigationWithinPage) pageScaleConstraintsSet().setNeedsReset(true); // Give the pinch viewport's scroll layer its initial size. page()->frameHost().pinchViewport().mainFrameDidChangeSize(); // Make sure link highlight from previous page is cleared. m_linkHighlights.clear(); endActiveFlingAnimation(); m_userGestureObserved = false; } void WebViewImpl::willInsertBody(WebLocalFrameImpl* webframe) { if (webframe != mainFrameImpl()) return; if (!m_page->mainFrame()->isLocalFrame()) return; // If we get to the <body> tag and we have no pending stylesheet and import load, we // can be fairly confident we'll have something sensible to paint soon and // can turn off deferred commits. if (m_page->deprecatedLocalMainFrame()->document()->isRenderingReady()) resumeTreeViewCommits(); } void WebViewImpl::didRemoveAllPendingStylesheet(WebLocalFrameImpl* webframe) { if (webframe != mainFrameImpl()) return; // If we have no more stylesheets to load and we're past the body tag, // we should have something to paint and should start as soon as possible. if (m_page->deprecatedLocalMainFrame()->document()->body()) resumeTreeViewCommits(); } void WebViewImpl::resumeTreeViewCommits() { if (m_layerTreeView) m_layerTreeView->setDeferCommits(false); } void WebViewImpl::postLayoutResize(WebLocalFrameImpl* webframe) { FrameView* view = webframe->frame()->view(); if (webframe == mainFrame()) view->resize(mainFrameSize()); else view->resize(webframe->frameView()->size()); } void WebViewImpl::layoutUpdated(WebLocalFrameImpl* webframe) { if (!m_client || !webframe->frame()->isLocalRoot()) return; // If we finished a layout while in deferred commit mode, // that means it's time to start producing frames again so un-defer. resumeTreeViewCommits(); if (m_shouldAutoResize && webframe->frame() && webframe->frame()->view()) { WebSize frameSize = webframe->frame()->view()->frameRect().size(); if (frameSize != m_size) { m_size = frameSize; page()->frameHost().pinchViewport().setSize(m_size); pageScaleConstraintsSet().didChangeViewSize(m_size); m_client->didAutoResize(m_size); sendResizeEventAndRepaint(); } } if (pageScaleConstraintsSet().constraintsDirty()) refreshPageScaleFactorAfterLayout(); FrameView* view = webframe->frame()->view(); postLayoutResize(webframe); // Relayout immediately to avoid violating the rule that needsLayout() // isn't set at the end of a layout. if (view->needsLayout()) view->layout(); // In case we didn't have a size when the top controls were updated. didUpdateTopControls(); m_client->didUpdateLayout(); } void WebViewImpl::didChangeContentsSize() { pageScaleConstraintsSet().didChangeContentsSize(contentsSize(), pageScaleFactor()); } void WebViewImpl::pageScaleFactorChanged() { pageScaleConstraintsSet().setNeedsReset(false); updateLayerTreeViewport(); if (m_inspectorOverlay) m_inspectorOverlay->update(); #ifdef MINIBLINK_NOT_IMPLEMENTED m_devToolsEmulator->viewportChanged(); #endif // MINIBLINK_NOT_IMPLEMENTED m_client->pageScaleFactorChanged(); } bool WebViewImpl::useExternalPopupMenus() { return shouldUseExternalPopupMenus; } void WebViewImpl::startDragging(LocalFrame* frame, const WebDragData& dragData, WebDragOperationsMask mask, const WebImage& dragImage, const WebPoint& dragImageOffset) { if (!m_client) return; ASSERT(!m_doingDragAndDrop); m_doingDragAndDrop = true; m_client->startDragging(WebLocalFrameImpl::fromFrame(frame), dragData, mask, dragImage, dragImageOffset); } void WebViewImpl::setIgnoreInputEvents(bool newValue) { ASSERT(m_ignoreInputEvents != newValue); m_ignoreInputEvents = newValue; } void WebViewImpl::setBackgroundColorOverride(WebColor color) { m_backgroundColorOverride = color; updateLayerTreeBackgroundColor(); } void WebViewImpl::setZoomFactorOverride(float zoomFactor) { m_zoomFactorOverride = zoomFactor; setZoomLevel(zoomLevel()); } void WebViewImpl::addPageOverlay(WebPageOverlay* overlay, int zOrder) { if (!m_pageOverlays) m_pageOverlays = PageOverlayList::create(this); m_pageOverlays->add(overlay, zOrder); } void WebViewImpl::removePageOverlay(WebPageOverlay* overlay) { if (m_pageOverlays && m_pageOverlays->remove(overlay) && m_pageOverlays->empty()) m_pageOverlays = nullptr; } void WebViewImpl::setOverlayLayer(GraphicsLayer* layer) { if (!m_rootGraphicsLayer) return; if (!m_page->mainFrame()->isLocalFrame()) return; m_page->frameHost().pinchViewport().containerLayer()->addChild(layer); } Element* WebViewImpl::focusedElement() const { Frame* frame = m_page->focusController().focusedFrame(); if (!frame || !frame->isLocalFrame()) return 0; Document* document = toLocalFrame(frame)->document(); if (!document) return 0; return document->focusedElement(); } HitTestResult WebViewImpl::hitTestResultForViewportPos(const IntPoint& posInViewport) { IntPoint rootFramePoint(m_page->frameHost().pinchViewport().viewportToRootFrame(posInViewport)); return hitTestResultForRootFramePos(rootFramePoint); } HitTestResult WebViewImpl::hitTestResultForRootFramePos(const IntPoint& posInRootFrame) { if (!m_page->mainFrame()->isLocalFrame()) return HitTestResult(); IntPoint docPoint(m_page->deprecatedLocalMainFrame()->view()->rootFrameToContents(posInRootFrame)); HitTestResult result = m_page->deprecatedLocalMainFrame()->eventHandler().hitTestResultAtPoint(docPoint, HitTestRequest::ReadOnly | HitTestRequest::Active); result.setToShadowHostIfInUserAgentShadowRoot(); return result; } WebHitTestResult WebViewImpl::hitTestResultForTap(const WebPoint& tapPointWindowPos, const WebSize& tapArea) { if (!m_page->mainFrame()->isLocalFrame()) return HitTestResult(); WebGestureEvent tapEvent; tapEvent.x = tapPointWindowPos.x; tapEvent.y = tapPointWindowPos.y; tapEvent.type = WebInputEvent::GestureTap; tapEvent.data.tap.tapCount = 1; tapEvent.data.tap.width = tapArea.width; tapEvent.data.tap.height = tapArea.height; PlatformGestureEventBuilder platformEvent(mainFrameImpl()->frameView(), tapEvent); HitTestResult result = m_page->deprecatedLocalMainFrame()->eventHandler().hitTestResultForGestureEvent(platformEvent, HitTestRequest::ReadOnly | HitTestRequest::Active).hitTestResult(); result.setToShadowHostIfInUserAgentShadowRoot(); return result; } void WebViewImpl::setTabsToLinks(bool enable) { m_tabsToLinks = enable; } bool WebViewImpl::tabsToLinks() const { return m_tabsToLinks; } void WebViewImpl::suppressInvalidations(bool enable) { if (m_client) m_client->suppressCompositorScheduling(enable); } void WebViewImpl::setRootGraphicsLayer(GraphicsLayer* layer) { if (!m_layerTreeView) return; suppressInvalidations(true); PinchViewport& pinchViewport = page()->frameHost().pinchViewport(); pinchViewport.attachToLayerTree(layer, graphicsLayerFactory()); if (layer) { m_rootGraphicsLayer = pinchViewport.rootGraphicsLayer(); m_rootLayer = pinchViewport.rootGraphicsLayer()->platformLayer(); m_rootTransformLayer = pinchViewport.rootGraphicsLayer(); updateRootLayerTransform(); m_layerTreeView->setRootLayer(*m_rootLayer); // We register viewport layers here since there may not be a layer // tree view prior to this point. page()->frameHost().pinchViewport().registerLayersWithTreeView(m_layerTreeView); if (m_pageOverlays) m_pageOverlays->update(); // TODO(enne): Work around page visibility changes not being // propogated to the WebView in some circumstances. This needs to // be refreshed here when setting a new root layer to avoid being // stuck in a presumed incorrectly invisible state. bool visible = page()->visibilityState() == PageVisibilityStateVisible; m_layerTreeView->setVisible(visible); } else { m_rootGraphicsLayer = nullptr; m_rootLayer = nullptr; m_rootTransformLayer = nullptr; // This means that we're transitioning to a new page. Suppress // commits until Blink generates invalidations so we don't // attempt to paint too early in the next page load. m_layerTreeView->setDeferCommits(true); m_layerTreeView->clearRootLayer(); page()->frameHost().pinchViewport().clearLayersForTreeView(m_layerTreeView); } suppressInvalidations(false); } void WebViewImpl::invalidateRect(const IntRect& rect) { if (m_layerTreeView) updateLayerTreeViewport(); else if (m_client) m_client->didInvalidateRect(rect); } GraphicsLayerFactory* WebViewImpl::graphicsLayerFactory() const { return m_graphicsLayerFactory.get(); } DeprecatedPaintLayerCompositor* WebViewImpl::compositor() const { if (!page() || !page()->mainFrame() || !page()->mainFrame()->isLocalFrame()) return 0; if (!page()->deprecatedLocalMainFrame()->document() || !page()->deprecatedLocalMainFrame()->document()->layoutView()) return 0; return page()->deprecatedLocalMainFrame()->document()->layoutView()->compositor(); } void WebViewImpl::registerForAnimations(WebLayer* layer) { if (m_layerTreeView) m_layerTreeView->registerForAnimations(layer); } GraphicsLayer* WebViewImpl::rootGraphicsLayer() { return m_rootGraphicsLayer; } void WebViewImpl::scheduleAnimation() { if (m_layerTreeView) { m_layerTreeView->setNeedsAnimate(); return; } if (m_client) m_client->scheduleAnimation(); } void WebViewImpl::attachCompositorAnimationTimeline(WebCompositorAnimationTimeline* timeline) { if (m_layerTreeView) m_layerTreeView->attachCompositorAnimationTimeline(timeline); } void WebViewImpl::detachCompositorAnimationTimeline(WebCompositorAnimationTimeline* timeline) { if (m_layerTreeView) m_layerTreeView->detachCompositorAnimationTimeline(timeline); } void WebViewImpl::initializeLayerTreeView() { if (m_client) { m_client->initializeLayerTreeView(); m_layerTreeView = m_client->layerTreeView(); } if (WebDevToolsAgentImpl* devTools = mainFrameDevToolsAgentImpl()) devTools->layerTreeViewChanged(m_layerTreeView); m_page->settings().setAcceleratedCompositingEnabled(m_layerTreeView != 0); if (!m_layerTreeView) // weolar return; // FIXME: only unittests, click to play, Android priting, and printing (for headers and footers) // make this assert necessary. We should make them not hit this code and then delete allowsBrokenNullLayerTreeView. ASSERT(m_layerTreeView || !m_client || m_client->allowsBrokenNullLayerTreeView()); } void WebViewImpl::applyViewportDeltas( const WebFloatSize& pinchViewportDelta, const WebFloatSize& layoutViewportDelta, const WebFloatSize& elasticOverscrollDelta, float pageScaleDelta, float topControlsShownRatioDelta) { if (!mainFrameImpl()) return; FrameView* frameView = mainFrameImpl()->frameView(); if (!frameView) return; topControls().setShownRatio(topControls().shownRatio() + topControlsShownRatioDelta); FloatPoint pinchViewportOffset = page()->frameHost().pinchViewport().visibleRect().location(); pinchViewportOffset.move(pinchViewportDelta.width, pinchViewportDelta.height); setPageScaleFactorAndLocation(pageScaleFactor() * pageScaleDelta, pinchViewportOffset); if (pageScaleDelta != 1) m_doubleTapZoomPending = false; m_elasticOverscroll += elasticOverscrollDelta; frameView->didUpdateElasticOverscroll(); ScrollableArea* layoutViewport = frameView->layoutViewportScrollableArea(); DoublePoint layoutViewportPosition = layoutViewport->scrollPositionDouble() + DoubleSize(layoutViewportDelta.width, layoutViewportDelta.height); if (layoutViewport->scrollPositionDouble() != layoutViewportPosition) { layoutViewport->setScrollPosition(layoutViewportPosition, CompositorScroll); frameView->setWasScrolledByUser(true); } } void WebViewImpl::recordFrameTimingEvent(FrameTimingEventType eventType, int64_t frameId, const WebVector<WebFrameTimingEvent>& events) { Frame* frame = m_page ? m_page->mainFrame() : 0; while (frame && frame->frameID() != frameId) { frame = frame->tree().traverseNext(); } if (!frame || !frame->domWindow() || !frame->domWindow()->document()) return; // Can't find frame, it may have been cleaned up from the DOM. #ifdef MINIBLINK_NOT_IMPLEMENTED blink::DOMWindow* domWindow = frame->domWindow(); blink::Performance* performance = DOMWindowPerformance::performance(*domWindow); for (size_t i = 0; i < events.size(); ++i) { if (eventType == CompositeEvent) performance->addCompositeTiming(domWindow->document(), events[i].sourceFrame, events[i].startTime); else if (eventType == RenderEvent) performance->addRenderTiming(domWindow->document(), events[i].sourceFrame, events[i].startTime, events[i].finishTime); } #endif // MINIBLINK_NOT_IMPLEMENTED } void WebViewImpl::updateLayerTreeViewport() { if (!page() || !m_layerTreeView) return; m_layerTreeView->setPageScaleFactorAndLimits(pageScaleFactor(), minimumPageScaleFactor(), maximumPageScaleFactor()); } void WebViewImpl::updateLayerTreeBackgroundColor() { if (!m_layerTreeView) return; m_layerTreeView->setBackgroundColor(alphaChannel(m_backgroundColorOverride) ? m_backgroundColorOverride : backgroundColor()); } void WebViewImpl::updateLayerTreeDeviceScaleFactor() { ASSERT(page()); ASSERT(m_layerTreeView); float deviceScaleFactor = m_compositorDeviceScaleFactorOverride ? m_compositorDeviceScaleFactorOverride : page()->deviceScaleFactor(); m_layerTreeView->setDeviceScaleFactor(deviceScaleFactor); } void WebViewImpl::updateRootLayerTransform() { // If we don't have a root graphics layer, we won't bother trying to find // or update the transform layer. if (!m_rootGraphicsLayer) return; if (m_rootTransformLayer) { TransformationMatrix transform; transform.translate(m_rootLayerOffset.width, m_rootLayerOffset.height); transform = transform.scale(m_rootLayerScale); m_rootTransformLayer->setTransform(transform); } } bool WebViewImpl::detectContentOnTouch(const GestureEventWithHitTestResults& targetedEvent) { if (!m_page->mainFrame()->isLocalFrame()) return false; // Need a local copy of the hit test as setToShadowHostIfInUserAgentShadowRoot() will modify it. HitTestResult touchHit = targetedEvent.hitTestResult(); touchHit.setToShadowHostIfInUserAgentShadowRoot(); if (touchHit.isContentEditable()) return false; Node* node = touchHit.innerNode(); if (!node || !node->isTextNode()) return false; // Ignore when tapping on links or nodes listening to click events, unless the click event is on the // body element, in which case it's unlikely that the original node itself was intended to be clickable. for (; node && !isHTMLBodyElement(*node); node = LayoutTreeBuilderTraversal::parent(*node)) { if (node->isLink() || node->willRespondToTouchEvents() || node->willRespondToMouseClickEvents()) return false; } WebContentDetectionResult content = m_client->detectContentAround(touchHit); if (!content.isValid()) return false; m_client->scheduleContentIntent(content.intent()); return true; } void WebViewImpl::setVisibilityState(WebPageVisibilityState visibilityState, bool isInitialState) { ASSERT(visibilityState == WebPageVisibilityStateVisible || visibilityState == WebPageVisibilityStateHidden || visibilityState == WebPageVisibilityStatePrerender); if (page()) m_page->setVisibilityState(static_cast<PageVisibilityState>(static_cast<int>(visibilityState)), isInitialState); if (m_layerTreeView) { bool visible = visibilityState == WebPageVisibilityStateVisible; m_layerTreeView->setVisible(visible); } } bool WebViewImpl::requestPointerLock() { return m_client && m_client->requestPointerLock(); } void WebViewImpl::requestPointerUnlock() { if (m_client) m_client->requestPointerUnlock(); } bool WebViewImpl::isPointerLocked() { return m_client && m_client->isPointerLocked(); } void WebViewImpl::pointerLockMouseEvent(const WebInputEvent& event) { OwnPtr<UserGestureIndicator> gestureIndicator; AtomicString eventType; switch (event.type) { case WebInputEvent::MouseDown: eventType = EventTypeNames::mousedown; gestureIndicator = adoptPtr(new UserGestureIndicator(DefinitelyProcessingNewUserGesture)); m_pointerLockGestureToken = gestureIndicator->currentToken(); break; case WebInputEvent::MouseUp: eventType = EventTypeNames::mouseup; gestureIndicator = adoptPtr(new UserGestureIndicator(m_pointerLockGestureToken.release())); break; case WebInputEvent::MouseMove: eventType = EventTypeNames::mousemove; break; default: ASSERT_NOT_REACHED(); } const WebMouseEvent& mouseEvent = static_cast<const WebMouseEvent&>(event); if (page()) page()->pointerLockController().dispatchLockedMouseEvent( PlatformMouseEventBuilder(mainFrameImpl()->frameView(), mouseEvent), eventType); } bool WebViewImpl::shouldDisableDesktopWorkarounds() { if (!settings()->viewportEnabled()) return false; // A document is considered adapted to small screen UAs if one of these holds: // 1. The author specified viewport has a constrained width that is equal to // the initial viewport width. // 2. The author has disabled viewport zoom. const PageScaleConstraints& constraints = pageScaleConstraintsSet().pageDefinedConstraints(); if (!mainFrameImpl() || !mainFrameImpl()->frameView()) return false; return mainFrameImpl()->frameView()->layoutSize().width() == m_size.width || (constraints.minimumScale == constraints.maximumScale && constraints.minimumScale != -1); } void WebViewImpl::forceNextWebGLContextCreationToFail() { #if 1 // def MINIBLINK_NOT_IMPLEMENTED WebGLRenderingContext::forceNextWebGLContextCreationToFail(); #endif // MINIBLINK_NOT_IMPLEMENTED } void WebViewImpl::forceNextDrawingBufferCreationToFail() { #if 1 // def MINIBLINK_NOT_IMPLEMENTED DrawingBuffer::forceNextDrawingBufferCreationToFail(); #endif // MINIBLINK_NOT_IMPLEMENTED } void WebViewImpl::setMainFrameTopContentInset(int offset) { if (mainFrameImpl()) mainFrameImpl()->setTopContentInset(offset); if (m_layerTreeView) m_layerTreeView->SetHudLayerTopInset(offset); } } // namespace blink ```
```c++ // // write_at.hpp // ~~~~~~~~~~~~ // // // file LICENSE_1_0.txt or copy at path_to_url // #ifndef ASIO_WRITE_AT_HPP #define ASIO_WRITE_AT_HPP #if defined(_MSC_VER) && (_MSC_VER >= 1200) # pragma once #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) #include "asio/detail/config.hpp" #include <cstddef> #include "asio/async_result.hpp" #include "asio/completion_condition.hpp" #include "asio/detail/cstdint.hpp" #include "asio/error.hpp" #if !defined(ASIO_NO_EXTENSIONS) # include "asio/basic_streambuf_fwd.hpp" #endif // !defined(ASIO_NO_EXTENSIONS) #include "asio/detail/push_options.hpp" namespace asio { namespace detail { template <typename> class initiate_async_write_at; #if !defined(ASIO_NO_IOSTREAM) template <typename> class initiate_async_write_at_streambuf; #endif // !defined(ASIO_NO_IOSTREAM) } // namespace detail /** * @defgroup write_at asio::write_at * * @brief The @c write_at function is a composed operation that writes a * certain amount of data at a specified offset before returning. */ /*@{*/ /// Write all of the supplied data at the specified offset before returning. /** * This function is used to write a certain number of bytes of data to a random * access device at a specified offset. The call will block until one of the * following conditions is true: * * @li All of the data in the supplied buffers has been written. That is, the * bytes transferred is equal to the sum of the buffer sizes. * * @li An error occurred. * * This operation is implemented in terms of zero or more calls to the device's * write_some_at function. * * @param d The device to which the data is to be written. The type must support * the SyncRandomAccessWriteDevice concept. * * @param offset The offset at which the data will be written. * * @param buffers One or more buffers containing the data to be written. The sum * of the buffer sizes indicates the maximum number of bytes to write to the * device. * * @returns The number of bytes transferred. * * @throws asio::system_error Thrown on failure. * * @par Example * To write a single data buffer use the @ref buffer function as follows: * @code asio::write_at(d, 42, asio::buffer(data, size)); @endcode * See the @ref buffer documentation for information on writing multiple * buffers in one go, and how to use it with arrays, boost::array or * std::vector. * * @note This overload is equivalent to calling: * @code asio::write_at( * d, offset, buffers, * asio::transfer_all()); @endcode */ template <typename SyncRandomAccessWriteDevice, typename ConstBufferSequence> std::size_t write_at(SyncRandomAccessWriteDevice& d, uint64_t offset, const ConstBufferSequence& buffers); /// Write all of the supplied data at the specified offset before returning. /** * This function is used to write a certain number of bytes of data to a random * access device at a specified offset. The call will block until one of the * following conditions is true: * * @li All of the data in the supplied buffers has been written. That is, the * bytes transferred is equal to the sum of the buffer sizes. * * @li An error occurred. * * This operation is implemented in terms of zero or more calls to the device's * write_some_at function. * * @param d The device to which the data is to be written. The type must support * the SyncRandomAccessWriteDevice concept. * * @param offset The offset at which the data will be written. * * @param buffers One or more buffers containing the data to be written. The sum * of the buffer sizes indicates the maximum number of bytes to write to the * device. * * @param ec Set to indicate what error occurred, if any. * * @returns The number of bytes transferred. * * @par Example * To write a single data buffer use the @ref buffer function as follows: * @code asio::write_at(d, 42, * asio::buffer(data, size), ec); @endcode * See the @ref buffer documentation for information on writing multiple * buffers in one go, and how to use it with arrays, boost::array or * std::vector. * * @note This overload is equivalent to calling: * @code asio::write_at( * d, offset, buffers, * asio::transfer_all(), ec); @endcode */ template <typename SyncRandomAccessWriteDevice, typename ConstBufferSequence> std::size_t write_at(SyncRandomAccessWriteDevice& d, uint64_t offset, const ConstBufferSequence& buffers, asio::error_code& ec); /// Write a certain amount of data at a specified offset before returning. /** * This function is used to write a certain number of bytes of data to a random * access device at a specified offset. The call will block until one of the * following conditions is true: * * @li All of the data in the supplied buffers has been written. That is, the * bytes transferred is equal to the sum of the buffer sizes. * * @li The completion_condition function object returns 0. * * This operation is implemented in terms of zero or more calls to the device's * write_some_at function. * * @param d The device to which the data is to be written. The type must support * the SyncRandomAccessWriteDevice concept. * * @param offset The offset at which the data will be written. * * @param buffers One or more buffers containing the data to be written. The sum * of the buffer sizes indicates the maximum number of bytes to write to the * device. * * @param completion_condition The function object to be called to determine * whether the write operation is complete. The signature of the function object * must be: * @code std::size_t completion_condition( * // Result of latest write_some_at operation. * const asio::error_code& error, * * // Number of bytes transferred so far. * std::size_t bytes_transferred * ); @endcode * A return value of 0 indicates that the write operation is complete. A * non-zero return value indicates the maximum number of bytes to be written on * the next call to the device's write_some_at function. * * @returns The number of bytes transferred. * * @throws asio::system_error Thrown on failure. * * @par Example * To write a single data buffer use the @ref buffer function as follows: * @code asio::write_at(d, 42, asio::buffer(data, size), * asio::transfer_at_least(32)); @endcode * See the @ref buffer documentation for information on writing multiple * buffers in one go, and how to use it with arrays, boost::array or * std::vector. */ template <typename SyncRandomAccessWriteDevice, typename ConstBufferSequence, typename CompletionCondition> std::size_t write_at(SyncRandomAccessWriteDevice& d, uint64_t offset, const ConstBufferSequence& buffers, CompletionCondition completion_condition); /// Write a certain amount of data at a specified offset before returning. /** * This function is used to write a certain number of bytes of data to a random * access device at a specified offset. The call will block until one of the * following conditions is true: * * @li All of the data in the supplied buffers has been written. That is, the * bytes transferred is equal to the sum of the buffer sizes. * * @li The completion_condition function object returns 0. * * This operation is implemented in terms of zero or more calls to the device's * write_some_at function. * * @param d The device to which the data is to be written. The type must support * the SyncRandomAccessWriteDevice concept. * * @param offset The offset at which the data will be written. * * @param buffers One or more buffers containing the data to be written. The sum * of the buffer sizes indicates the maximum number of bytes to write to the * device. * * @param completion_condition The function object to be called to determine * whether the write operation is complete. The signature of the function object * must be: * @code std::size_t completion_condition( * // Result of latest write_some_at operation. * const asio::error_code& error, * * // Number of bytes transferred so far. * std::size_t bytes_transferred * ); @endcode * A return value of 0 indicates that the write operation is complete. A * non-zero return value indicates the maximum number of bytes to be written on * the next call to the device's write_some_at function. * * @param ec Set to indicate what error occurred, if any. * * @returns The number of bytes written. If an error occurs, returns the total * number of bytes successfully transferred prior to the error. */ template <typename SyncRandomAccessWriteDevice, typename ConstBufferSequence, typename CompletionCondition> std::size_t write_at(SyncRandomAccessWriteDevice& d, uint64_t offset, const ConstBufferSequence& buffers, CompletionCondition completion_condition, asio::error_code& ec); #if !defined(ASIO_NO_EXTENSIONS) #if !defined(ASIO_NO_IOSTREAM) /// Write all of the supplied data at the specified offset before returning. /** * This function is used to write a certain number of bytes of data to a random * access device at a specified offset. The call will block until one of the * following conditions is true: * * @li All of the data in the supplied basic_streambuf has been written. * * @li An error occurred. * * This operation is implemented in terms of zero or more calls to the device's * write_some_at function. * * @param d The device to which the data is to be written. The type must support * the SyncRandomAccessWriteDevice concept. * * @param offset The offset at which the data will be written. * * @param b The basic_streambuf object from which data will be written. * * @returns The number of bytes transferred. * * @throws asio::system_error Thrown on failure. * * @note This overload is equivalent to calling: * @code asio::write_at( * d, 42, b, * asio::transfer_all()); @endcode */ template <typename SyncRandomAccessWriteDevice, typename Allocator> std::size_t write_at(SyncRandomAccessWriteDevice& d, uint64_t offset, basic_streambuf<Allocator>& b); /// Write all of the supplied data at the specified offset before returning. /** * This function is used to write a certain number of bytes of data to a random * access device at a specified offset. The call will block until one of the * following conditions is true: * * @li All of the data in the supplied basic_streambuf has been written. * * @li An error occurred. * * This operation is implemented in terms of zero or more calls to the device's * write_some_at function. * * @param d The device to which the data is to be written. The type must support * the SyncRandomAccessWriteDevice concept. * * @param offset The offset at which the data will be written. * * @param b The basic_streambuf object from which data will be written. * * @param ec Set to indicate what error occurred, if any. * * @returns The number of bytes transferred. * * @note This overload is equivalent to calling: * @code asio::write_at( * d, 42, b, * asio::transfer_all(), ec); @endcode */ template <typename SyncRandomAccessWriteDevice, typename Allocator> std::size_t write_at(SyncRandomAccessWriteDevice& d, uint64_t offset, basic_streambuf<Allocator>& b, asio::error_code& ec); /// Write a certain amount of data at a specified offset before returning. /** * This function is used to write a certain number of bytes of data to a random * access device at a specified offset. The call will block until one of the * following conditions is true: * * @li All of the data in the supplied basic_streambuf has been written. * * @li The completion_condition function object returns 0. * * This operation is implemented in terms of zero or more calls to the device's * write_some_at function. * * @param d The device to which the data is to be written. The type must support * the SyncRandomAccessWriteDevice concept. * * @param offset The offset at which the data will be written. * * @param b The basic_streambuf object from which data will be written. * * @param completion_condition The function object to be called to determine * whether the write operation is complete. The signature of the function object * must be: * @code std::size_t completion_condition( * // Result of latest write_some_at operation. * const asio::error_code& error, * * // Number of bytes transferred so far. * std::size_t bytes_transferred * ); @endcode * A return value of 0 indicates that the write operation is complete. A * non-zero return value indicates the maximum number of bytes to be written on * the next call to the device's write_some_at function. * * @returns The number of bytes transferred. * * @throws asio::system_error Thrown on failure. */ template <typename SyncRandomAccessWriteDevice, typename Allocator, typename CompletionCondition> std::size_t write_at(SyncRandomAccessWriteDevice& d, uint64_t offset, basic_streambuf<Allocator>& b, CompletionCondition completion_condition); /// Write a certain amount of data at a specified offset before returning. /** * This function is used to write a certain number of bytes of data to a random * access device at a specified offset. The call will block until one of the * following conditions is true: * * @li All of the data in the supplied basic_streambuf has been written. * * @li The completion_condition function object returns 0. * * This operation is implemented in terms of zero or more calls to the device's * write_some_at function. * * @param d The device to which the data is to be written. The type must support * the SyncRandomAccessWriteDevice concept. * * @param offset The offset at which the data will be written. * * @param b The basic_streambuf object from which data will be written. * * @param completion_condition The function object to be called to determine * whether the write operation is complete. The signature of the function object * must be: * @code std::size_t completion_condition( * // Result of latest write_some_at operation. * const asio::error_code& error, * * // Number of bytes transferred so far. * std::size_t bytes_transferred * ); @endcode * A return value of 0 indicates that the write operation is complete. A * non-zero return value indicates the maximum number of bytes to be written on * the next call to the device's write_some_at function. * * @param ec Set to indicate what error occurred, if any. * * @returns The number of bytes written. If an error occurs, returns the total * number of bytes successfully transferred prior to the error. */ template <typename SyncRandomAccessWriteDevice, typename Allocator, typename CompletionCondition> std::size_t write_at(SyncRandomAccessWriteDevice& d, uint64_t offset, basic_streambuf<Allocator>& b, CompletionCondition completion_condition, asio::error_code& ec); #endif // !defined(ASIO_NO_IOSTREAM) #endif // !defined(ASIO_NO_EXTENSIONS) /*@}*/ /** * @defgroup async_write_at asio::async_write_at * * @brief The @c async_write_at function is a composed asynchronous operation * that writes a certain amount of data at the specified offset before * completion. */ /*@{*/ /// Start an asynchronous operation to write all of the supplied data at the /// specified offset. /** * This function is used to asynchronously write a certain number of bytes of * data to a random access device at a specified offset. It is an initiating * function for an @ref asynchronous_operation, and always returns immediately. * The asynchronous operation will continue until one of the following * conditions is true: * * @li All of the data in the supplied buffers has been written. That is, the * bytes transferred is equal to the sum of the buffer sizes. * * @li An error occurred. * * This operation is implemented in terms of zero or more calls to the device's * async_write_some_at function, and is known as a <em>composed operation</em>. * The program must ensure that the device performs no <em>overlapping</em> * write operations (such as async_write_at, the device's async_write_some_at * function, or any other composed operations that perform writes) until this * operation completes. Operations are overlapping if the regions defined by * their offsets, and the numbers of bytes to write, intersect. * * @param d The device to which the data is to be written. The type must support * the AsyncRandomAccessWriteDevice concept. * * @param offset The offset at which the data will be written. * * @param buffers One or more buffers containing the data to be written. * Although the buffers object may be copied as necessary, ownership of the * underlying memory blocks is retained by the caller, which must guarantee * that they remain valid until the completion handler is called. * * @param token The @ref completion_token that will be used to produce a * completion handler, which will be called when the write completes. * Potential completion tokens include @ref use_future, @ref use_awaitable, * @ref yield_context, or a function object with the correct completion * signature. The function signature of the completion handler must be: * @code void handler( * // Result of operation. * const asio::error_code& error, * * // Number of bytes written from the buffers. If an error * // occurred, this will be less than the sum of the buffer sizes. * std::size_t bytes_transferred * ); @endcode * Regardless of whether the asynchronous operation completes immediately or * not, the completion handler will not be invoked from within this function. * On immediate completion, invocation of the handler will be performed in a * manner equivalent to using asio::post(). * * @par Completion Signature * @code void(asio::error_code, std::size_t) @endcode * * @par Example * To write a single data buffer use the @ref buffer function as follows: * @code * asio::async_write_at(d, 42, asio::buffer(data, size), handler); * @endcode * See the @ref buffer documentation for information on writing multiple * buffers in one go, and how to use it with arrays, boost::array or * std::vector. * * @par Per-Operation Cancellation * This asynchronous operation supports cancellation for the following * asio::cancellation_type values: * * @li @c cancellation_type::terminal * * @li @c cancellation_type::partial * * if they are also supported by the @c AsyncRandomAccessWriteDevice type's * async_write_some_at operation. */ template <typename AsyncRandomAccessWriteDevice, typename ConstBufferSequence, ASIO_COMPLETION_TOKEN_FOR(void (asio::error_code, std::size_t)) WriteToken = default_completion_token_t< typename AsyncRandomAccessWriteDevice::executor_type>> auto async_write_at(AsyncRandomAccessWriteDevice& d, uint64_t offset, const ConstBufferSequence& buffers, WriteToken&& token = default_completion_token_t< typename AsyncRandomAccessWriteDevice::executor_type>()) -> decltype( async_initiate<WriteToken, void (asio::error_code, std::size_t)>( declval<detail::initiate_async_write_at< AsyncRandomAccessWriteDevice>>(), token, offset, buffers, transfer_all())); /// Start an asynchronous operation to write a certain amount of data at the /// specified offset. /** * This function is used to asynchronously write a certain number of bytes of * data to a random access device at a specified offset. It is an initiating * function for an @ref asynchronous_operation, and always returns immediately. * The asynchronous operation will continue until one of the following * conditions is true: * * @li All of the data in the supplied buffers has been written. That is, the * bytes transferred is equal to the sum of the buffer sizes. * * @li The completion_condition function object returns 0. * * This operation is implemented in terms of zero or more calls to the device's * async_write_some_at function, and is known as a <em>composed operation</em>. * The program must ensure that the device performs no <em>overlapping</em> * write operations (such as async_write_at, the device's async_write_some_at * function, or any other composed operations that perform writes) until this * operation completes. Operations are overlapping if the regions defined by * their offsets, and the numbers of bytes to write, intersect. * * @param d The device to which the data is to be written. The type must support * the AsyncRandomAccessWriteDevice concept. * * @param offset The offset at which the data will be written. * * @param buffers One or more buffers containing the data to be written. * Although the buffers object may be copied as necessary, ownership of the * underlying memory blocks is retained by the caller, which must guarantee * that they remain valid until the completion handler is called. * * @param completion_condition The function object to be called to determine * whether the write operation is complete. The signature of the function object * must be: * @code std::size_t completion_condition( * // Result of latest async_write_some_at operation. * const asio::error_code& error, * * // Number of bytes transferred so far. * std::size_t bytes_transferred * ); @endcode * A return value of 0 indicates that the write operation is complete. A * non-zero return value indicates the maximum number of bytes to be written on * the next call to the device's async_write_some_at function. * * @param token The @ref completion_token that will be used to produce a * completion handler, which will be called when the write completes. * Potential completion tokens include @ref use_future, @ref use_awaitable, * @ref yield_context, or a function object with the correct completion * signature. The function signature of the completion handler must be: * @code void handler( * // Result of operation. * const asio::error_code& error, * * // Number of bytes written from the buffers. If an error * // occurred, this will be less than the sum of the buffer sizes. * std::size_t bytes_transferred * ); @endcode * Regardless of whether the asynchronous operation completes immediately or * not, the completion handler will not be invoked from within this function. * On immediate completion, invocation of the handler will be performed in a * manner equivalent to using asio::post(). * * @par Completion Signature * @code void(asio::error_code, std::size_t) @endcode * * @par Example * To write a single data buffer use the @ref buffer function as follows: * @code asio::async_write_at(d, 42, * asio::buffer(data, size), * asio::transfer_at_least(32), * handler); @endcode * See the @ref buffer documentation for information on writing multiple * buffers in one go, and how to use it with arrays, boost::array or * std::vector. * * @par Per-Operation Cancellation * This asynchronous operation supports cancellation for the following * asio::cancellation_type values: * * @li @c cancellation_type::terminal * * @li @c cancellation_type::partial * * if they are also supported by the @c AsyncRandomAccessWriteDevice type's * async_write_some_at operation. */ template <typename AsyncRandomAccessWriteDevice, typename ConstBufferSequence, typename CompletionCondition, ASIO_COMPLETION_TOKEN_FOR(void (asio::error_code, std::size_t)) WriteToken = default_completion_token_t< typename AsyncRandomAccessWriteDevice::executor_type>> auto async_write_at(AsyncRandomAccessWriteDevice& d, uint64_t offset, const ConstBufferSequence& buffers, CompletionCondition completion_condition, WriteToken&& token = default_completion_token_t< typename AsyncRandomAccessWriteDevice::executor_type>()) -> decltype( async_initiate<WriteToken, void (asio::error_code, std::size_t)>( declval<detail::initiate_async_write_at< AsyncRandomAccessWriteDevice>>(), token, offset, buffers, static_cast<CompletionCondition&&>(completion_condition))); #if !defined(ASIO_NO_EXTENSIONS) #if !defined(ASIO_NO_IOSTREAM) /// Start an asynchronous operation to write all of the supplied data at the /// specified offset. /** * This function is used to asynchronously write a certain number of bytes of * data to a random access device at a specified offset. It is an initiating * function for an @ref asynchronous_operation, and always returns immediately. * The asynchronous operation will continue until one of the following * conditions is true: * * @li All of the data in the supplied basic_streambuf has been written. * * @li An error occurred. * * This operation is implemented in terms of zero or more calls to the device's * async_write_some_at function, and is known as a <em>composed operation</em>. * The program must ensure that the device performs no <em>overlapping</em> * write operations (such as async_write_at, the device's async_write_some_at * function, or any other composed operations that perform writes) until this * operation completes. Operations are overlapping if the regions defined by * their offsets, and the numbers of bytes to write, intersect. * * @param d The device to which the data is to be written. The type must support * the AsyncRandomAccessWriteDevice concept. * * @param offset The offset at which the data will be written. * * @param b A basic_streambuf object from which data will be written. Ownership * of the streambuf is retained by the caller, which must guarantee that it * remains valid until the completion handler is called. * * @param token The @ref completion_token that will be used to produce a * completion handler, which will be called when the write completes. * Potential completion tokens include @ref use_future, @ref use_awaitable, * @ref yield_context, or a function object with the correct completion * signature. The function signature of the completion handler must be: * @code void handler( * // Result of operation. * const asio::error_code& error, * * // Number of bytes written from the buffers. If an error * // occurred, this will be less than the sum of the buffer sizes. * std::size_t bytes_transferred * ); @endcode * Regardless of whether the asynchronous operation completes immediately or * not, the completion handler will not be invoked from within this function. * On immediate completion, invocation of the handler will be performed in a * manner equivalent to using asio::post(). * * @par Completion Signature * @code void(asio::error_code, std::size_t) @endcode * * @par Per-Operation Cancellation * This asynchronous operation supports cancellation for the following * asio::cancellation_type values: * * @li @c cancellation_type::terminal * * @li @c cancellation_type::partial * * if they are also supported by the @c AsyncRandomAccessWriteDevice type's * async_write_some_at operation. */ template <typename AsyncRandomAccessWriteDevice, typename Allocator, ASIO_COMPLETION_TOKEN_FOR(void (asio::error_code, std::size_t)) WriteToken = default_completion_token_t< typename AsyncRandomAccessWriteDevice::executor_type>> auto async_write_at(AsyncRandomAccessWriteDevice& d, uint64_t offset, basic_streambuf<Allocator>& b, WriteToken&& token = default_completion_token_t< typename AsyncRandomAccessWriteDevice::executor_type>()) -> decltype( async_initiate<WriteToken, void (asio::error_code, std::size_t)>( declval<detail::initiate_async_write_at_streambuf< AsyncRandomAccessWriteDevice>>(), token, offset, &b, transfer_all())); /// Start an asynchronous operation to write a certain amount of data at the /// specified offset. /** * This function is used to asynchronously write a certain number of bytes of * data to a random access device at a specified offset. It is an initiating * function for an @ref asynchronous_operation, and always returns immediately. * The asynchronous operation will continue until one of the following * conditions is true: * * @li All of the data in the supplied basic_streambuf has been written. * * @li The completion_condition function object returns 0. * * This operation is implemented in terms of zero or more calls to the device's * async_write_some_at function, and is known as a <em>composed operation</em>. * The program must ensure that the device performs no <em>overlapping</em> * write operations (such as async_write_at, the device's async_write_some_at * function, or any other composed operations that perform writes) until this * operation completes. Operations are overlapping if the regions defined by * their offsets, and the numbers of bytes to write, intersect. * * @param d The device to which the data is to be written. The type must support * the AsyncRandomAccessWriteDevice concept. * * @param offset The offset at which the data will be written. * * @param b A basic_streambuf object from which data will be written. Ownership * of the streambuf is retained by the caller, which must guarantee that it * remains valid until the completion handler is called. * * @param completion_condition The function object to be called to determine * whether the write operation is complete. The signature of the function object * must be: * @code std::size_t completion_condition( * // Result of latest async_write_some_at operation. * const asio::error_code& error, * * // Number of bytes transferred so far. * std::size_t bytes_transferred * ); @endcode * A return value of 0 indicates that the write operation is complete. A * non-zero return value indicates the maximum number of bytes to be written on * the next call to the device's async_write_some_at function. * * @param token The @ref completion_token that will be used to produce a * completion handler, which will be called when the write completes. * Potential completion tokens include @ref use_future, @ref use_awaitable, * @ref yield_context, or a function object with the correct completion * signature. The function signature of the completion handler must be: * @code void handler( * // Result of operation. * const asio::error_code& error, * * // Number of bytes written from the buffers. If an error * // occurred, this will be less than the sum of the buffer sizes. * std::size_t bytes_transferred * ); @endcode * Regardless of whether the asynchronous operation completes immediately or * not, the completion handler will not be invoked from within this function. * On immediate completion, invocation of the handler will be performed in a * manner equivalent to using asio::post(). * * @par Completion Signature * @code void(asio::error_code, std::size_t) @endcode * * @par Per-Operation Cancellation * This asynchronous operation supports cancellation for the following * asio::cancellation_type values: * * @li @c cancellation_type::terminal * * @li @c cancellation_type::partial * * if they are also supported by the @c AsyncRandomAccessWriteDevice type's * async_write_some_at operation. */ template <typename AsyncRandomAccessWriteDevice, typename Allocator, typename CompletionCondition, ASIO_COMPLETION_TOKEN_FOR(void (asio::error_code, std::size_t)) WriteToken = default_completion_token_t< typename AsyncRandomAccessWriteDevice::executor_type>> auto async_write_at(AsyncRandomAccessWriteDevice& d, uint64_t offset, basic_streambuf<Allocator>& b, CompletionCondition completion_condition, WriteToken&& token = default_completion_token_t< typename AsyncRandomAccessWriteDevice::executor_type>()) -> decltype( async_initiate<WriteToken, void (asio::error_code, std::size_t)>( declval<detail::initiate_async_write_at_streambuf< AsyncRandomAccessWriteDevice>>(), token, offset, &b, static_cast<CompletionCondition&&>(completion_condition))); #endif // !defined(ASIO_NO_IOSTREAM) #endif // !defined(ASIO_NO_EXTENSIONS) /*@}*/ } // namespace asio #include "asio/detail/pop_options.hpp" #include "asio/impl/write_at.hpp" #endif // ASIO_WRITE_AT_HPP ```
CD64 can refer to: CD64 (biology) CD64 (Nintendo)
CSN International is relayed by numerous low-powered translators nationwide. As a religious station, CSN International flagship KAWZ is allowed to place translators anywhere in the United States, regardless of distance from its parent station's coverage area. Alabama Alaska Arizona Arkansas California Colorado Florida Georgia Hawaii Idaho Illinois Indiana Iowa Kansas Kentucky Louisiana Maryland Michigan Minnesota Mississippi Missouri Montana Nebraska Nevada The Sun Valley translator is unusual in that translators are not normally allowed on the 87.9 frequency. The translator was originally licensed at 88.1 MHz, but was allowed to move to 87.9 MHz to avoid interfering with 88.3 in Sparks, Nevada. New Jersey New Mexico New York North Carolina North Dakota Ohio Oklahoma Oregon Pennsylvania South Carolina South Dakota Tennessee Texas Utah Virginia Washington Wisconsin Wyoming Christian radio stations in the United States American radio networks
```c /* $OpenBSD: w_close.c,v 1.1 2016/05/07 19:05:22 guenther Exp $ */ /* * * Permission to use, copy, modify, and distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ #include <unistd.h> #include "cancel.h" int close(int fd) { int ret; ENTER_CANCEL_POINT(0); ret = HIDDEN(close)(fd); LEAVE_CANCEL_POINT(1); return (ret); } DEF_CANCEL(close); ```
Iptor Supply Chain Systems, formerly International Business Systems (IBS), is a supply chain management company that provides professional services and enterprise resource management software for distributors and wholesalers, with its headquarters in Stockholm, Sweden. They were previously publicly traded on the Stockholm Stock Exchange and have offices in several countries. They are rated by AMR Research and Frost & Sullivan as the largest supply chain execution solutions company by revenue. The company rebranded as Iptor in September 2016. History The company was founded as IBS in 1978 by Staffan Ahlberg and Gunnar Rylander. Both decided to form the company by turning the IT division of Ekonomisk Företagsledning into an independent company. Their first major project was to develop an order processing system for Alfa Laval subsidiaries. The company went public on the Stockholm Stock Exchange in 1986. Around the same time they entered into partnership with IBM and became a supplier of software for the IBM AS/400. Ahlberg retired as the CEO of IBS in 2002 and was the longest serving CEO of a public company in Europe. IBS expanded into Asia in 1996. The company also has a presence in the United States. IBS purchased Australian-based international software developer IDS Enterprise Systems in 2005. At the time of the deal, IDS had revenue of €12 million and more than 100 employees and operations in the United Kingdom, the Netherlands, Australia, and Thailand. In 2011, IBS was purchased by Symphony Technology Group. The deal made Symphony a 94.9% shareholder of IBS and the company went from being publicly traded to private. Products and services IBS offers supply chain management software and services to distributors and wholesalers for small, medium and Fortune 500 companies. They also offer logistics, demand management, customer relationship management, financial management, and business intelligence services. IBS Enterprise distribution resource management is a software suite from IBS that automates supply chain management including inventory planning, purchasing and supplier management, warehouse optimization, value-added services, demand management and returns processing. IBS provides a publishing-specific platform referred to as the Bookmaster. The platform is an enterprise management business software designed for publishers and book distributors in both the print and digital markets. It incorporates financial and supply chain management within the software that also integrates with web-based financial transactions and business management processes. IBS also offers a platform referred to as Dynaman which supports warehouse operations. The software is designed to improve process control, data capturing and visibility of inventory. It also allows integration with supply chain partner operations. IBS also offer a connectivity platform designed to allow organizations and applications to connect and communicate with each other. Referred to as the IBS Integrator, it contains more than 12 solution-specific adapters which enable it to connect between different systems and business partners. IBS has won multiple awards for the IBS Integrator. Awards IBS received the Supply-Chain Council Award in 2003, and was named to the list of Top 100 Companies in 2002 by Frontline magazine. References Software companies established in 1978 Companies based in Stockholm Supply chain software companies Swedish companies established in 1978
Hüseyin Gürsoy (1934 – 1 September 1993) was a Turkish wrestler. He competed in the men's freestyle 87 kg at the 1968 Summer Olympics. References External links 1934 births 1993 deaths Turkish male sport wrestlers Olympic wrestlers for Turkey Wrestlers at the 1968 Summer Olympics People from Oltu 20th-century Turkish people
Steady Run Township is a township in Keokuk County, Iowa, USA. References Townships in Keokuk County, Iowa Townships in Iowa
Koh Dong-jin (born 1961) is a South Korean businessman. In 2015, Koh became the CEO of Samsung. In January 2020, Koh stepped down as Samsung CEO to become a co-CEO leading the company's IT and mobile communications division. References 1961 births Living people Samsung people South Korean chief executives
In enzymology, a [citrate (pro-3S)-lyase] ligase () is an enzyme that catalyzes the chemical reaction ATP + acetate + citrate (pro-3S)-lyase(thiol form) AMP + diphosphate + citrate (pro-3S)-lyase(acetyl form) The 3 substrates of this enzyme are ATP, acetate, and citrate (pro-3S)-lyase(thiol form), whereas its 3 products are AMP, diphosphate, and citrate (pro-3S)-lyase(acetyl form). This enzyme belongs to the family of ligases, specifically those forming carbon-sulfur bonds as acid-thiol ligases. The systematic name of this enzyme class is acetate:citrate (pro-3S)-lyase(thiol-form) ligase (AMP-forming). Other names in common use include citrate lyase ligase, citrate lyase synthetase, acetate: SH-acyl-carrier-protein enzyme ligase (AMP), acetate:HS-citrate lyase ligase, and acetate:citrate-(pro-3S)-lyase(thiol-form) ligase (AMP-forming). This enzyme participates in two-component system - general. References EC 6.2.1 Enzymes of unknown structure
```objective-c //===-- SymbolFileDWARF.h --------------------------------------*- C++ -*-===// // // See path_to_url for license information. // //===your_sha256_hash------===// #ifndef LLDB_SOURCE_PLUGINS_SYMBOLFILE_DWARF_SYMBOLFILEDWARF_H #define LLDB_SOURCE_PLUGINS_SYMBOLFILE_DWARF_SYMBOLFILEDWARF_H #include <list> #include <map> #include <mutex> #include <optional> #include <unordered_map> #include <vector> #include "llvm/ADT/DenseMap.h" #include "llvm/ADT/SetVector.h" #include "llvm/Support/Threading.h" #include "lldb/Core/UniqueCStringMap.h" #include "lldb/Core/dwarf.h" #include "lldb/Expression/DWARFExpressionList.h" #include "lldb/Symbol/DebugMacros.h" #include "lldb/Symbol/SymbolContext.h" #include "lldb/Symbol/SymbolFile.h" #include "lldb/Target/Statistics.h" #include "lldb/Utility/ConstString.h" #include "lldb/Utility/Flags.h" #include "lldb/Utility/RangeMap.h" #include "lldb/lldb-private.h" #include "DWARFContext.h" #include "DWARFDataExtractor.h" #include "DWARFDefines.h" #include "DWARFIndex.h" #include "UniqueDWARFASTType.h" // Forward Declarations for this DWARF plugin class DebugMapModule; class DWARFAbbreviationDeclaration; class DWARFAbbreviationDeclarationSet; class DWARFCompileUnit; class DWARFDebugAbbrev; class DWARFDebugAranges; class DWARFDebugInfo; class DWARFDebugInfoEntry; class DWARFDebugLine; class DWARFDebugRanges; class DWARFDeclContext; class DWARFFormValue; class DWARFTypeUnit; class SymbolFileDWARFDebugMap; class SymbolFileDWARFDwo; class SymbolFileDWARFDwp; #define DIE_IS_BEING_PARSED ((lldb_private::Type *)1) class SymbolFileDWARF : public lldb_private::SymbolFileCommon, public lldb_private::UserID { /// LLVM RTTI support. static char ID; public: /// LLVM RTTI support. /// \{ bool isA(const void *ClassID) const override { return ClassID == &ID || SymbolFileCommon::isA(ClassID); } static bool classof(const SymbolFile *obj) { return obj->isA(&ID); } /// \} friend class SymbolFileDWARFDebugMap; friend class SymbolFileDWARFDwo; friend class DebugMapModule; friend class DWARFCompileUnit; friend class DWARFDIE; friend class DWARFASTParserClang; // Static Functions static void Initialize(); static void Terminate(); static void DebuggerInitialize(lldb_private::Debugger &debugger); static llvm::StringRef GetPluginNameStatic() { return "dwarf"; } static llvm::StringRef GetPluginDescriptionStatic(); static lldb_private::SymbolFile * CreateInstance(lldb::ObjectFileSP objfile_sp); // Constructors and Destructors SymbolFileDWARF(lldb::ObjectFileSP objfile_sp, lldb_private::SectionList *dwo_section_list); ~SymbolFileDWARF() override; uint32_t CalculateAbilities() override; void InitializeObject() override; // Compile Unit function calls lldb::LanguageType ParseLanguage(lldb_private::CompileUnit &comp_unit) override; lldb_private::XcodeSDK ParseXcodeSDK(lldb_private::CompileUnit &comp_unit) override; size_t ParseFunctions(lldb_private::CompileUnit &comp_unit) override; bool ParseLineTable(lldb_private::CompileUnit &comp_unit) override; bool ParseDebugMacros(lldb_private::CompileUnit &comp_unit) override; bool ForEachExternalModule( lldb_private::CompileUnit &, llvm::DenseSet<lldb_private::SymbolFile *> &, llvm::function_ref<bool(lldb_private::Module &)>) override; bool ParseSupportFiles(lldb_private::CompileUnit &comp_unit, lldb_private::FileSpecList &support_files) override; bool ParseIsOptimized(lldb_private::CompileUnit &comp_unit) override; size_t ParseTypes(lldb_private::CompileUnit &comp_unit) override; bool ParseImportedModules( const lldb_private::SymbolContext &sc, std::vector<lldb_private::SourceModule> &imported_modules) override; size_t ParseBlocksRecursive(lldb_private::Function &func) override; size_t ParseVariablesForContext(const lldb_private::SymbolContext &sc) override; lldb_private::Type *ResolveTypeUID(lldb::user_id_t type_uid) override; std::optional<ArrayInfo> GetDynamicArrayInfoForUID( lldb::user_id_t type_uid, const lldb_private::ExecutionContext *exe_ctx) override; bool CompleteType(lldb_private::CompilerType &compiler_type) override; lldb_private::Type *ResolveType(const DWARFDIE &die, bool assert_not_being_parsed = true, bool resolve_function_context = false); lldb_private::CompilerDecl GetDeclForUID(lldb::user_id_t uid) override; lldb_private::CompilerDeclContext GetDeclContextForUID(lldb::user_id_t uid) override; lldb_private::CompilerDeclContext GetDeclContextContainingUID(lldb::user_id_t uid) override; void ParseDeclsForContext(lldb_private::CompilerDeclContext decl_ctx) override; uint32_t ResolveSymbolContext(const lldb_private::Address &so_addr, lldb::SymbolContextItem resolve_scope, lldb_private::SymbolContext &sc) override; lldb_private::Status CalculateFrameVariableError(lldb_private::StackFrame &frame) override; uint32_t ResolveSymbolContext( const lldb_private::SourceLocationSpec &src_location_spec, lldb::SymbolContextItem resolve_scope, lldb_private::SymbolContextList &sc_list) override; void FindGlobalVariables(lldb_private::ConstString name, const lldb_private::CompilerDeclContext &parent_decl_ctx, uint32_t max_matches, lldb_private::VariableList &variables) override; void FindGlobalVariables(const lldb_private::RegularExpression &regex, uint32_t max_matches, lldb_private::VariableList &variables) override; void FindFunctions(const lldb_private::Module::LookupInfo &lookup_info, const lldb_private::CompilerDeclContext &parent_decl_ctx, bool include_inlines, lldb_private::SymbolContextList &sc_list) override; void FindFunctions(const lldb_private::RegularExpression &regex, bool include_inlines, lldb_private::SymbolContextList &sc_list) override; void GetMangledNamesForFunction( const std::string &scope_qualified_name, std::vector<lldb_private::ConstString> &mangled_names) override; void FindTypes(lldb_private::ConstString name, const lldb_private::CompilerDeclContext &parent_decl_ctx, uint32_t max_matches, llvm::DenseSet<lldb_private::SymbolFile *> &searched_symbol_files, lldb_private::TypeMap &types) override; void FindTypes(llvm::ArrayRef<lldb_private::CompilerContext> pattern, lldb_private::LanguageSet languages, llvm::DenseSet<SymbolFile *> &searched_symbol_files, lldb_private::TypeMap &types) override; void GetTypes(lldb_private::SymbolContextScope *sc_scope, lldb::TypeClass type_mask, lldb_private::TypeList &type_list) override; llvm::Expected<lldb::TypeSystemSP> GetTypeSystemForLanguage(lldb::LanguageType language) override; lldb_private::CompilerDeclContext FindNamespace( lldb_private::ConstString name, const lldb_private::CompilerDeclContext &parent_decl_ctx) override; void PreloadSymbols() override; std::recursive_mutex &GetModuleMutex() const override; // PluginInterface protocol llvm::StringRef GetPluginName() override { return GetPluginNameStatic(); } DWARFDebugAbbrev *DebugAbbrev(); DWARFDebugInfo &DebugInfo(); DWARFDebugRanges *GetDebugRanges(); static bool SupportedVersion(uint16_t version); DWARFDIE GetDeclContextDIEContainingDIE(const DWARFDIE &die); bool HasForwardDeclForClangType(const lldb_private::CompilerType &compiler_type); lldb_private::CompileUnit * GetCompUnitForDWARFCompUnit(DWARFCompileUnit &dwarf_cu); virtual void GetObjCMethods(lldb_private::ConstString class_name, llvm::function_ref<bool(DWARFDIE die)> callback); bool Supports_DW_AT_APPLE_objc_complete_type(DWARFUnit *cu); lldb_private::DebugMacrosSP ParseDebugMacros(lldb::offset_t *offset); static DWARFDIE GetParentSymbolContextDIE(const DWARFDIE &die); lldb::ModuleSP GetExternalModule(lldb_private::ConstString name); typedef std::map<lldb_private::ConstString, lldb::ModuleSP> ExternalTypeModuleMap; /// Return the list of Clang modules imported by this SymbolFile. const ExternalTypeModuleMap &getExternalTypeModules() const { return m_external_type_modules; } virtual DWARFDIE GetDIE(const DIERef &die_ref); DWARFDIE GetDIE(lldb::user_id_t uid); lldb::user_id_t GetUID(const DWARFBaseDIE &die) { return GetUID(die.GetDIERef()); } lldb::user_id_t GetUID(const std::optional<DIERef> &ref) { return ref ? GetUID(*ref) : LLDB_INVALID_UID; } lldb::user_id_t GetUID(DIERef ref); std::shared_ptr<SymbolFileDWARFDwo> GetDwoSymbolFileForCompileUnit(DWARFUnit &dwarf_cu, const DWARFDebugInfoEntry &cu_die); virtual std::optional<uint32_t> GetDwoNum() { return std::nullopt; } /// If this is a DWARF object with a single CU, return its DW_AT_dwo_id. std::optional<uint64_t> GetDWOId(); static bool DIEInDeclContext(const lldb_private::CompilerDeclContext &parent_decl_ctx, const DWARFDIE &die); std::vector<std::unique_ptr<lldb_private::CallEdge>> ParseCallEdgesInFunction(UserID func_id) override; void Dump(lldb_private::Stream &s) override; void DumpClangAST(lldb_private::Stream &s) override; lldb_private::DWARFContext &GetDWARFContext() { return m_context; } const std::shared_ptr<SymbolFileDWARFDwo> &GetDwpSymbolFile(); lldb_private::FileSpec GetFile(DWARFUnit &unit, size_t file_idx); static llvm::Expected<lldb::TypeSystemSP> GetTypeSystem(DWARFUnit &unit); static DWARFASTParser *GetDWARFParser(DWARFUnit &unit); // CompilerDecl related functions static lldb_private::CompilerDecl GetDecl(const DWARFDIE &die); static lldb_private::CompilerDeclContext GetDeclContext(const DWARFDIE &die); static lldb_private::CompilerDeclContext GetContainingDeclContext(const DWARFDIE &die); static DWARFDeclContext GetDWARFDeclContext(const DWARFDIE &die); static lldb::LanguageType LanguageTypeFromDWARF(uint64_t val); static lldb::LanguageType GetLanguage(DWARFUnit &unit); /// Same as GetLanguage() but reports all C++ versions as C++ (no version). static lldb::LanguageType GetLanguageFamily(DWARFUnit &unit); lldb_private::StatsDuration::Duration GetDebugInfoParseTime() override { return m_parse_time; } lldb_private::StatsDuration::Duration GetDebugInfoIndexTime() override; lldb_private::StatsDuration &GetDebugInfoParseTimeRef() { return m_parse_time; } virtual lldb::offset_t GetVendorDWARFOpcodeSize(const lldb_private::DataExtractor &data, const lldb::offset_t data_offset, const uint8_t op) const { return LLDB_INVALID_OFFSET; } virtual bool ParseVendorDWARFOpcode(uint8_t op, const lldb_private::DataExtractor &opcodes, lldb::offset_t &offset, std::vector<lldb_private::Value> &stack) const { return false; } lldb_private::ConstString ConstructFunctionDemangledName(const DWARFDIE &die); protected: typedef llvm::DenseMap<const DWARFDebugInfoEntry *, lldb_private::Type *> DIEToTypePtr; typedef llvm::DenseMap<const DWARFDebugInfoEntry *, lldb::VariableSP> DIEToVariableSP; typedef llvm::DenseMap<const DWARFDebugInfoEntry *, lldb::opaque_compiler_type_t> DIEToClangType; typedef llvm::DenseMap<lldb::opaque_compiler_type_t, DIERef> ClangTypeToDIE; SymbolFileDWARF(const SymbolFileDWARF &) = delete; const SymbolFileDWARF &operator=(const SymbolFileDWARF &) = delete; virtual void LoadSectionData(lldb::SectionType sect_type, lldb_private::DWARFDataExtractor &data); bool DeclContextMatchesThisSymbolFile( const lldb_private::CompilerDeclContext &decl_ctx); uint32_t CalculateNumCompileUnits() override; lldb::CompUnitSP ParseCompileUnitAtIndex(uint32_t index) override; lldb_private::TypeList &GetTypeList() override; lldb::CompUnitSP ParseCompileUnit(DWARFCompileUnit &dwarf_cu); virtual DWARFCompileUnit * GetDWARFCompileUnit(lldb_private::CompileUnit *comp_unit); DWARFUnit *GetNextUnparsedDWARFCompileUnit(DWARFUnit *prev_cu); bool GetFunction(const DWARFDIE &die, lldb_private::SymbolContext &sc); lldb_private::Function *ParseFunction(lldb_private::CompileUnit &comp_unit, const DWARFDIE &die); size_t ParseBlocksRecursive(lldb_private::CompileUnit &comp_unit, lldb_private::Block *parent_block, const DWARFDIE &die, lldb::addr_t subprogram_low_pc, uint32_t depth); size_t ParseTypes(const lldb_private::SymbolContext &sc, const DWARFDIE &die, bool parse_siblings, bool parse_children); lldb::TypeSP ParseType(const lldb_private::SymbolContext &sc, const DWARFDIE &die, bool *type_is_new); bool ParseSupportFiles(DWARFUnit &dwarf_cu, const lldb::ModuleSP &module, lldb_private::FileSpecList &support_files); lldb_private::Type *ResolveTypeUID(const DWARFDIE &die, bool assert_not_being_parsed); lldb_private::Type *ResolveTypeUID(const DIERef &die_ref); lldb::VariableSP ParseVariableDIE(const lldb_private::SymbolContext &sc, const DWARFDIE &die, const lldb::addr_t func_low_pc); lldb::VariableSP ParseVariableDIECached(const lldb_private::SymbolContext &sc, const DWARFDIE &die); void ParseAndAppendGlobalVariable(const lldb_private::SymbolContext &sc, const DWARFDIE &die, lldb_private::VariableList &cc_variable_list); size_t ParseVariablesInFunctionContext(const lldb_private::SymbolContext &sc, const DWARFDIE &die, const lldb::addr_t func_low_pc); size_t ParseVariablesInFunctionContextRecursive( const lldb_private::SymbolContext &sc, const DWARFDIE &die, lldb::addr_t func_low_pc, DIEArray &accumulator); size_t PopulateBlockVariableList(lldb_private::VariableList &variable_list, const lldb_private::SymbolContext &sc, llvm::ArrayRef<DIERef> variable_dies, lldb::addr_t func_low_pc); DIEArray MergeBlockAbstractParameters(const DWARFDIE &block_die, DIEArray &&variable_dies); bool ClassOrStructIsVirtual(const DWARFDIE &die); // Given a die_offset, figure out the symbol context representing that die. bool ResolveFunction(const DWARFDIE &die, bool include_inlines, lldb_private::SymbolContextList &sc_list); /// Resolve functions and (possibly) blocks for the given file address and a /// compile unit. The compile unit comes from the sc argument and it must be /// set. The results of the lookup (if any) are written back to the symbol /// context. void ResolveFunctionAndBlock(lldb::addr_t file_vm_addr, bool lookup_block, lldb_private::SymbolContext &sc); virtual lldb::TypeSP FindDefinitionTypeForDWARFDeclContext(const DWARFDIE &die); virtual lldb::TypeSP FindCompleteObjCDefinitionTypeForDIE(const DWARFDIE &die, lldb_private::ConstString type_name, bool must_be_implementation); lldb_private::Symbol * GetObjCClassSymbol(lldb_private::ConstString objc_class_name); lldb::TypeSP GetTypeForDIE(const DWARFDIE &die, bool resolve_function_context = false); void SetDebugMapModule(const lldb::ModuleSP &module_sp) { m_debug_map_module_wp = module_sp; } SymbolFileDWARFDebugMap *GetDebugMapSymfile(); DWARFDIE FindBlockContainingSpecification(const DIERef &func_die_ref, dw_offset_t spec_block_die_offset); DWARFDIE FindBlockContainingSpecification(const DWARFDIE &die, dw_offset_t spec_block_die_offset); virtual UniqueDWARFASTTypeMap &GetUniqueDWARFASTTypeMap(); bool DIEDeclContextsMatch(const DWARFDIE &die1, const DWARFDIE &die2); bool ClassContainsSelector(const DWARFDIE &class_die, lldb_private::ConstString selector); /// Parse call site entries (DW_TAG_call_site), including any nested call site /// parameters (DW_TAG_call_site_parameter). std::vector<std::unique_ptr<lldb_private::CallEdge>> CollectCallEdges(lldb::ModuleSP module, DWARFDIE function_die); /// If this symbol file is linked to by a debug map (see /// SymbolFileDWARFDebugMap), and \p file_addr is a file address relative to /// an object file, adjust \p file_addr so that it is relative to the main /// binary. Returns the adjusted address, or \p file_addr if no adjustment is /// needed, on success and LLDB_INVALID_ADDRESS otherwise. lldb::addr_t FixupAddress(lldb::addr_t file_addr); bool FixupAddress(lldb_private::Address &addr); typedef llvm::SetVector<lldb_private::Type *> TypeSet; void GetTypes(const DWARFDIE &die, dw_offset_t min_die_offset, dw_offset_t max_die_offset, uint32_t type_mask, TypeSet &type_set); typedef lldb_private::RangeDataVector<lldb::addr_t, lldb::addr_t, lldb_private::Variable *> GlobalVariableMap; GlobalVariableMap &GetGlobalAranges(); void UpdateExternalModuleListIfNeeded(); virtual DIEToTypePtr &GetDIEToType() { return m_die_to_type; } virtual DIEToVariableSP &GetDIEToVariable() { return m_die_to_variable_sp; } virtual DIEToClangType &GetForwardDeclDieToClangType() { return m_forward_decl_die_to_clang_type; } virtual ClangTypeToDIE &GetForwardDeclClangTypeToDie() { return m_forward_decl_clang_type_to_die; } void BuildCuTranslationTable(); std::optional<uint32_t> GetDWARFUnitIndex(uint32_t cu_idx); struct DecodedUID { SymbolFileDWARF &dwarf; DIERef ref; }; std::optional<DecodedUID> DecodeUID(lldb::user_id_t uid); void FindDwpSymbolFile(); const lldb_private::FileSpecList &GetTypeUnitSupportFiles(DWARFTypeUnit &tu); void InitializeFirstCodeAddressRecursive( const lldb_private::SectionList &section_list); void InitializeFirstCodeAddress(); lldb::ModuleWP m_debug_map_module_wp; SymbolFileDWARFDebugMap *m_debug_map_symfile; llvm::once_flag m_dwp_symfile_once_flag; std::shared_ptr<SymbolFileDWARFDwo> m_dwp_symfile; lldb_private::DWARFContext m_context; llvm::once_flag m_info_once_flag; std::unique_ptr<DWARFDebugInfo> m_info; std::unique_ptr<DWARFDebugAbbrev> m_abbr; std::unique_ptr<GlobalVariableMap> m_global_aranges_up; typedef std::unordered_map<lldb::offset_t, lldb_private::DebugMacrosSP> DebugMacrosMap; DebugMacrosMap m_debug_macros_map; ExternalTypeModuleMap m_external_type_modules; std::unique_ptr<lldb_private::DWARFIndex> m_index; bool m_fetched_external_modules : 1; lldb_private::LazyBool m_supports_DW_AT_APPLE_objc_complete_type; typedef std::set<DIERef> DIERefSet; typedef llvm::StringMap<DIERefSet> NameToOffsetMap; NameToOffsetMap m_function_scope_qualified_name_map; std::unique_ptr<DWARFDebugRanges> m_ranges; UniqueDWARFASTTypeMap m_unique_ast_type_map; DIEToTypePtr m_die_to_type; DIEToVariableSP m_die_to_variable_sp; DIEToClangType m_forward_decl_die_to_clang_type; ClangTypeToDIE m_forward_decl_clang_type_to_die; llvm::DenseMap<dw_offset_t, lldb_private::FileSpecList> m_type_unit_support_files; std::vector<uint32_t> m_lldb_cu_to_dwarf_unit; /// DWARF does not provide a good way for traditional (concatenating) linkers /// to invalidate debug info describing dead-stripped code. These linkers will /// keep the debug info but resolve any addresses referring to such code as /// zero (BFD) or a small positive integer (zero + relocation addend -- GOLD). /// Try to filter out this debug info by comparing it to the lowest code /// address in the module. lldb::addr_t m_first_code_address = LLDB_INVALID_ADDRESS; lldb_private::StatsDuration m_parse_time; std::atomic_flag m_dwo_warning_issued = ATOMIC_FLAG_INIT; }; #endif // LLDB_SOURCE_PLUGINS_SYMBOLFILE_DWARF_SYMBOLFILEDWARF_H ```
The Grand Pavilion is an entertainment venue in Porthcawl, Bridgend County Borough, Wales, opened in 1932. It has an octagonal dome and extensive frontage, and was originally intended as a Palm Court for hosting tea dances, balls and civic functions. Construction of the Grand Pavilion commenced in the summer of 1931. The use of ferrocrete throughout - then a relatively new technology - meant that the construction was relatively quick and was complete by August 1932. The Grand Pavilion hosts a variety of events throughout the year including live theatre, concerts, ballroom dancing, conferences, dances, and culminating in the ever-popular Christmas pantomime. Recently, names such as Rob Brydon, Eddie Izzard, Elkie Brooks, Cerys Matthews, Hayley Westenra, Katherine Jenkins, Suzi Quatro, Ralph McTell, Joe Pasquale, and Gerry & The Pacemakers have all appeared on the Pavilion's stage. In 1957 a US Government travel ban prevented Paul Robeson from appearing in person at the Miners' Eisteddfod, however he still performed live via a secretly arranged transatlantic telephone link up. Fifty years on, in 2007, the Grand Pavilion celebrated this event with a concert featuring Sir Willard White. The Grand Pavilion is also a conference venue, and hosts civil wedding ceremonies, receptions and parties. The main hall features a fully equipped stage, and has a theatre seating capacity of 643. The hall also boasts one of the finest sprung dance floors anywhere in South Wales. The octagonal floor is regularly used for ballroom dancing classes and tea dances. Originally named the "lesser hall" (and subsequently the "Jubilee Room") the basement of the Pavilion houses a refurbished performance space now named "The Stage Door", which plays host to regular Comedy nights, folk and jazz nights, dance classes, theatre workshops, conferences and meetings. The Cafe Bar hosts its own series of events, such as Jazz, Chill-out sessions, Literary speaking and an Art Forum. Several metres to the west is the Seabank Hotel. Buildings and structures completed in 1932 Buildings and structures in Bridgend County Borough Porthcawl Theatres in Wales Tourist attractions in Bridgend County Borough
Anthony's poison arrow frog (Epipedobates anthonyi) is a species of poison dart frog in the family Dendrobatidae. The species is endemic to Ecuador and Peru. Etymology The specific name, anthonyi, is in honor of American mammalogist Harold Elmer Anthony (1890–1970), who was Curator of Mammals at the American Museum of Natural History. Description Anthony's poison arrow frog has a snout-to-vent length of about . The hind legs are short and robust. The dorsal surface is usually dark red or brown and there are several yellowish-white oblique stripes and a central longitudinal stripe. Geographic range Anthony's poison arrow frog is known only from a number of locations in southwestern Ecuador and northwestern Peru at heights of between above sea level. Habitat The natural habitat of E. anthonyi is the leaf litter on the floor of tropical dry forests, especially near streams. Biology Anthony's poison arrow frog is diurnal and terrestrial. Males are territorial. A clutch of 15 to 40 eggs is laid on the ground among leaf litter, and the male guards them till they hatch in about two weeks. He then carries the tadpoles on his back to a suitable water body where they develop (through metamorphosis) into frogs in about sixty days. Epibatidine, an extremely toxic nicotine-like substance, was first derived from and named for Epipedobates anthonyi. Once investigated for possible use as an analgesic agent, the alkaloid proved far too toxic for any application in human medicine and is presently used exclusively for research purposes. Status Anthony's poison arrow frog is listed as "Near Threatened" by the IUCN. Its population seems stable but it has a limited range, estimated to be less than , and its habitat is being degraded by pollution from agrochemicals. It is also collected for medicinal use. References Further reading Noble GK (1921). "Five new species of Salientia from South America". American Museum Novitates (29): 1-7. (Phyllobates anthonyi, new species, pp. 5–6, Figure 5). Epipedobates Frogs of South America Amphibians of Ecuador Amphibians of Peru Amphibians described in 1921 Taxa named by Gladwyn Kingsley Noble Taxonomy articles created by Polbot
```asciidoc // This assembly is included in the following assemblies: // // using/assembly-management-tasks.adoc [id='assembly-rolling-updates-{context}'] = Managing rolling updates Use annotations to manually trigger a rolling update of Kafka and other operands through the Cluster Operator. Initiate rolling updates of Kafka, Kafka Connect, MirrorMaker 2, and ZooKeeper clusters. Manually performing a rolling update on a specific pod or set of pods is usually only required in exceptional circumstances. However, rather than deleting the pods directly, if you perform the rolling update through the Cluster Operator you ensure the following: * The manual deletion of the pod does not conflict with simultaneous Cluster Operator operations, such as deleting other pods in parallel. * The Cluster Operator logic handles the Kafka configuration specifications, such as the number of in-sync replicas. //steps for manual rolling updates with strimzipodset include::../../modules/managing/proc-manual-rolling-update-strimzipodset.adoc[leveloffset=+1] //steps for manual rolling update with pods include::../../modules/managing/proc-manual-rolling-update-pods.adoc[leveloffset=+1] ```
The Piyangotepe Massacre was a mass killing in Turkey on May 16, 1979. The massacre resulted in the death of 7 people and the injury of 2 others. A generally left-wing coffeehouse was raided by right-wing militants in Piyangotepe, Ankara. Ali Bülent Orkan, one of the defendants, was executed after the September 12 coup. Massacre On May 16, 1979, on Refik Saydam Street in the Piyangotepe district of Keçiören district, was destroyed by right-wingers Ali Bülent Orkan, Nurullah Akdoğan, Erol Türkmen and Hasan. The militants asked those in the cafe to lie on the ground. At that time, 20 people in the coffee house complied. The attackers opened fire randomly on the people lying on the ground. The fatalities were Hüsamettin Kurban, Tuncay Sarıkaya, Mızrap Ali Taşkın, Erdoğan Doğan, Müslüm Doğan, Mehmet Turan, and Ahmet Turan. 2 people were seriously injured. The attackers fled in a taxi. Trial A statement by the Ankara Police Department on May 31, 1979, claimed that the defendants were also involved in various killings, injuries and rape before and after the incident. Ankara Police Department described the incident as follows:"The taxi with license plate 06 AT 126 belonging to Rıza Tüfekçi, used in the robbery, was usurped by Nurullah Akdoğan and Erol Türkmen, nicknamed 'Hasret', who were riding in front of the SBF as customers. The driver was taken to Bayındır Dam and tied to a tree. With the same car, Kırşehir Prison escapee Hüseyin Bozkurt. "Ali Bülent Orkan, who uses his pseudonym and an identified person, came to Çelik Kıraathanesi. Meanwhile, Akdoğan was waiting in the car, while three other armed people opened fire on those who were lying on the ground with three 14-gun pistols, which were determined to be used in various incidents."The main suspect of the massacre, Ali Bülent Orkan, was caught in İzmir on October 12, 1980. One of the defendants, Erol Türkmen, raided the house of Chief Inspector Hikmet Sökmener in Ankara on October 17, 1980. He injured Sökmener's wife, Bilgen Sökmener, and killed Sökmener's 12-year-old daughter. After the incident, under police pressure, Turkmen committed suicide by squeezing himself in the head. Ali Bülent Orkan was tried in Ankara Martial Law No. 1 Military Court and was sentenced to death on 24 June 1981. The Military Court of Cassation Chambers approved the execution on February 25, 1982. The decision was also accepted by the Consultative Assembly and was finally approved at the 112th meeting of the National Security Council, under the chairmanship of President Gen. Kenan Evren. Orkan was executed by hanging in Ankara Central Closed Prison on 13 August 1982. References Massacres in Turkey Political violence in Turkey
```c++ // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at // path_to_url #include <libs/vmd/test/test_assert_is_array_fail4.cxx> ```
Blue is the mark of a soda juice fruit and vitamins sold in Angola. The drink is available in 10 flavors. Released in 2005 by Refriango company, the market leader in Angola, it was awarded the Gold Medal at the International Monde Selection Quality. The Blue brand is available in distinct flavors which other Angolan carbonated soft drinks do not use. The drink's slogan is "life is a feast". Variants of the mark Blue Pulp - with pieces of fruit, orange and pineapple are the fruit that remain in the mouth (Launched in 2012) Blue Lemon-Lime Blue Orange - with concentrated orange juice Blue Passion fruit - With passion fruit juice concentrate Blue Pineapple Blue Tamarind Blue Coco Pineapple Blue Tropical Strawberry Blue Apple Blue Guarana Awards In 2013, Blue received a gold medal from the International Competition of Quality, Monde Selection. The highest award is only awarded to products which are distinguished by their quality, prestige and innovation worldwide. References Soft drinks African drinks Food and drink introduced in 2005 2005 establishments in Angola
Oberndorf an der Melk is a municipality in the district of Scheibbs in the Austrian state of Lower Austria. Population References Cities and towns in Scheibbs District
This article is a list of notable individuals who were born in and/or have lived in Prairie Village, Kansas. Arts and entertainment Film, television, and theatre Sandahl Bergman (1951– ), actress, dancer, stuntwoman Eric Darnell (1961– ), director, screenwriter, voice actor Chuck Norris (1940– ), actor, martial artist, producer Journalism Joe McGuff (1926–2006), Kansas City Star sportswriter and editor Ramesh Ponnuru (1974– ), columnist, pundit Literature Jason Aaron (1973– ), comic book writer Music Joyce DiDonato (1969– ), mezzo-soprano opera singer Abe Ismert, Eli Ismert, and Henry Ismert of the metal band Hammerhedd Business John Carmack (1970– ), computer programmer, co-founder of id Software Donald Fehr (1948– ), sports union executive Robert S. Kaplan (1957– ), President, Federal Reserve Bank of Dallas David Wittig (1955– ), energy executive Crime Debora Green (1951– ), convicted murderer Politics National Larry Winn (1919–2017), U.S. Representative from Kansas State Robert Bennett (1927–2000), 39th Governor of Kansas (1975–1979) Marci Francisco (1950– ), Kansas state legislator Jim Roth (1968– ), Oklahoma politician Science Dan Connolly, computer scientist Sports Baseball Hank Bauer (1922–2007), right fielder, manager George Brett (1953– ), Hall of Fame designated hitter, 1st & 3rd baseman Horse racing Ben Jones (1882–1961), thoroughbred horse trainer Horace Jones (1906–2001), thoroughbred horse trainer Other Ray Evans (1922–1999), football halfback Ross William Guignon (1993– ), tennis player Tom Watson (1949– ), professional golfer See also Lists of people from Kansas List of people from Johnson County, Kansas References Prairie Village, Kansas Prairie Village
The Bofors 152 mm kanon m/42 is a naval gun for use on ships. It was initially used aboard light cruisers and cruisers including the Swedish and the Dutch , after World War II. The last active ship to use the gun was the Peruvian Navy cruiser and was the largest naval gun still in active service prior to the commissioning of in October 2016, which is armed with the 155 mm Advanced Gun System. The 152 mm gun was first designed in 1939 by Bofors for the Koninklijke Marine cruiser Kijkduin, eventually named . After the German invasion of the Netherlands in 1940 these artillery pieces were confiscated by the Swedish Government and placed on the Swedish cruiser . References External links Tony DiGiulian, Netherlands 15 cm/53 (5.9") Sweden 15.2 cm/53 (6") Model 1942 Bofors Naval guns of the Netherlands Naval guns of Sweden World War II naval weapons Artillery of Sweden 152 mm artillery Weapons and ammunition introduced in 1943
Arkansaw may refer to: Arkansaw, Wisconsin, a census-designated place in Pepin County Arkansaw Territory, a U.S. territory from 1819 to 1836 See also Arkansas, a homophone
Doris J. Kelley is a former Iowa State Representative from the 20th District. She served in the Iowa House of Representatives from 2007 to 2011. Kelley served on several committees in the Iowa House – the Commerce committee; the Education committee; the Local Government committee; and the Ways and Means committee. She also served as vice-chair of the Administration and Regulation Appropriations Subcommittee. Kelley was elected in 2006 with 6,344 votes (52%), defeating Republican opponent David Wieland. In the November 2, 2010 general election, Kelley was defeated by Republican challenger Walt Rogers. From 1995 to 2000, Kelley held the position of Chief Spokesperson/Marketing Director at Cedar Falls Utilities' Communications Utility. Throughout her career, she has also held notable roles such as Director of Business Development at Black and Veatch, Director of Consulting Services at DesignLiNC, Incorporated, and Telecommunications Coordinator at the Iowa Association of Municipal Utilities. Kelley has a history of leadership roles, having served as the Past President of the Black Hawk Leadership Board of Directors and as a former Director of the Cedar Falls Main Street Program. References External links Representative Doris Kelley official Iowa General Assembly site Doris Kelley State Representative official constituency site Democratic Party members of the Iowa House of Representatives Living people Women state legislators in Iowa Year of birth missing (living people) Place of birth missing (living people) 21st-century American women
```go // Code generated by go-swagger; DO NOT EDIT. package models // This file was generated by the swagger tool. // Editing this file might prove futile when you re-run the swagger generate command import ( "context" "encoding/json" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" "github.com/go-openapi/swag" "github.com/go-openapi/validate" ) // InstanceActionInfo Variant wrapper containing the real action. // // swagger:model InstanceActionInfo type InstanceActionInfo struct { // Enumeration indicating what type of action is contained in the payload // Required: true // Enum: [FlushMetrics InstanceStart SendCtrlAltDel] ActionType *string `json:"action_type"` } // Validate validates this instance action info func (m *InstanceActionInfo) Validate(formats strfmt.Registry) error { var res []error if err := m.validateActionType(formats); err != nil { res = append(res, err) } if len(res) > 0 { return errors.CompositeValidationError(res...) } return nil } var instanceActionInfoTypeActionTypePropEnum []interface{} func init() { var res []string if err := json.Unmarshal([]byte(`["FlushMetrics","InstanceStart","SendCtrlAltDel"]`), &res); err != nil { panic(err) } for _, v := range res { instanceActionInfoTypeActionTypePropEnum = append(instanceActionInfoTypeActionTypePropEnum, v) } } const ( // InstanceActionInfoActionTypeFlushMetrics captures enum value "FlushMetrics" InstanceActionInfoActionTypeFlushMetrics string = "FlushMetrics" // InstanceActionInfoActionTypeInstanceStart captures enum value "InstanceStart" InstanceActionInfoActionTypeInstanceStart string = "InstanceStart" // InstanceActionInfoActionTypeSendCtrlAltDel captures enum value "SendCtrlAltDel" InstanceActionInfoActionTypeSendCtrlAltDel string = "SendCtrlAltDel" ) // prop value enum func (m *InstanceActionInfo) validateActionTypeEnum(path, location string, value string) error { if err := validate.EnumCase(path, location, value, instanceActionInfoTypeActionTypePropEnum, true); err != nil { return err } return nil } func (m *InstanceActionInfo) validateActionType(formats strfmt.Registry) error { if err := validate.Required("action_type", "body", m.ActionType); err != nil { return err } // value enum if err := m.validateActionTypeEnum("action_type", "body", *m.ActionType); err != nil { return err } return nil } // ContextValidate validates this instance action info based on context it is used func (m *InstanceActionInfo) ContextValidate(ctx context.Context, formats strfmt.Registry) error { return nil } // MarshalBinary interface implementation func (m *InstanceActionInfo) MarshalBinary() ([]byte, error) { if m == nil { return nil, nil } return swag.WriteJSON(m) } // UnmarshalBinary interface implementation func (m *InstanceActionInfo) UnmarshalBinary(b []byte) error { var res InstanceActionInfo if err := swag.ReadJSON(b, &res); err != nil { return err } *m = res return nil } ```
Yusuf Kironde Lule (10 April 1912 – 21 January 1985) was a Ugandan professor and civil servant who served as the fourth president of Uganda between 13 April and 20 June 1979. Early life Yusuf Lule was born on 10 April 1912 in Kampala. He was educated at King's College Budo (1929–34), Makerere University College, Kampala (1934–36), Fort Hare University at Alice, South Africa (1936–39) and the University of Edinburgh. He was initially a Muslim but later converted to Christianity while at King's College Budo. In 1947 Lule married Hannah Namuli Wamala at Kings College Budo's church, where he was a teacher and she was head girl. In 1959 the Democratic Party (DP) nominated Lule as a candidate to become Kattikiro (Prime Minister) of the subnational kingdom of Buganda. Many aristocratic figures in the kingdom distrusted Lule because of his Muslim origins, and Michael Kintu ultimately won the election. Upon Uganda's independence in 1962, he became chairman of the Public Service Commission. Lule served as the first black principal of Makerere University College from 1964 to 1970, and was assistant secretary-general of the Association of African Universities, in Accra, Ghana, between 1973 and 1978. Lule served as a minister in the pre-independence British colonial government and later as an assistant secretary-general of the Commonwealth Secretariat. He went into exile after Idi Amin came to power. Chairman of the Uganda National Liberation Front Following the outbreak of the Uganda–Tanzania War, Ugandan rebels and exiles began making preparations for the establishment of a new government to follow Idi Amin's regime. After the Tanzania People's Defence Force (TPDF) had captured substantial territory, President Julius Nyerere of Tanzania ordered it to halt to give time for the Ugandan rebels to convene and reorganise. The Ugandan rebels made due preparations, primarily led by former president Milton Obote and leftist intellectual Dani Wadada Nabudere in their own respective circles. As the Tanzanians began organising a conference for the rebels and exiles, Nyerere was reconsidering Obote's role in the movement. He did not want to give the impression that Tanzania was going to install a government of its own choice in Uganda by facilitating Obote's assumption of leadership of the rebel movement, and there was hostility to Obote from the Baganda people in southern Uganda as well as other countries such as Kenya. Nyerere also feared that Obote would stifle cooperation at the meeting and cause it to break up without success. He ultimately convinced Obote to refrain from attending. In place of Obote, many Ugandan exiles began favouring Lule, who was a Muganda and had the reputation of being a political moderate as well as a civil servant who was not tarnished by scandal or corrupt service in a past Ugandan regime. The Moshi Conference opened on 24 March 1979 in the Tanzanian town of Moshi, following an intense debate over which factions and persons could be admitted. That afternoon the delegates announced the formation of the Uganda National Liberation Front (UNLF), which was to be governed by a 30-strong National Consultative Committee (NCC) and an 11-strong National Executive Committee, the latter including three special commissions—Finance and Administration, Political and Diplomatic Affairs, and Military Affairs. The next two days were spent debating the balance of power among the governing bodies and the selection of a chairman for the organisation, which was hotly contested between Lule and Paulo Muwanga, an Obote supporter. After heated argument a consensus was reached whereby Lule would be given the chair and Muwanga would be made head of the Military Affairs Commission. President of Uganda Inauguration Caught unprepared by the fall of Kampala, Lule hurriedly compiled a list of ministers meant to represent the ethnic balances of Uganda's population. On 12 April 1979 Lule and his cabinet boarded a flight from Dar es Salaam to Entebbe to fly in for his inauguration. While the plane was stopped in Mwanza, Tanzanian officials decided to delay it there until they could ensure better security for a ceremony in Kampala. The next day Lule and his ministers reached Entebbe and were brought into Kampala in a TPDF motorcade in the late afternoon. Lule was then sworn in as President of Uganda in front of the Parliament building and gave a brief speech pledging to bring a return of law and order. Lule concluded by saying in Luganda, "Now it is our turn." Still feeling that Kampala was unsafe, Tanzanian officials quickly took Lule from Parliament and installed him in the Entebbe State House. Tenure Lule assumed office at a time when Uganda's national institutions were dysfunctional and the country was plagued by lawlessness and violence; he presided over a failed state. Lule disregarded the Moshi Conference agreements stipulating a weak presidential authority and attempted to assert his ability to operate under stronger powers provided by the constitution operative in Uganda before Amin's coup. Within days of assuming office Lule and his advisers began taking major decisions without consulting the NCC. He also snubbed the committee members by first missing their formal inauguration and, when the ceremony was rescheduled so he could be present, he gave a speech and departed before swearing them in, much to their displeasure. Lule then appointed ministers and deputy ministers to his cabinet without the NCC's approval. The members of the cabinet joined the NCC ex officio, and he ultimately appointed 24 ministers and 20 deputies, which then outnumbered the original councilors. Despite complaints from the NCC, Lule carried on making appointments and revising the structure of his cabinet. He also declared a reorganization of Ugandan's administration, dividing the country into four regions each subject to the authority of a regional commissioner. Lule further infuriated the NCC when his cabinet awarded its own members $5,000 worth of foreign exchange as a "rehabilitation allowance" despite the treasury having very little money. Lule responded to the councilors' anger by offering them the same allowance, which they rejected. He also distrusted the UNLA, which he considered to be made up of loyal Obote and Yoweri Museveni partisans. Lule's government withheld money to the army for this reason, and it played no role in overseeing the defeat of the remnants of Amin's forces. He planned on disbanding the UNLA and replacing it with a new "National Army", which angered the leaders of the former. The army was to be proportionately representative of all of Uganda's regions and stipulate education requirements for applicants. Lule secured a £100 million aid programme from Western countries, alienating leftists who feared he would sellout the country to international business interests. His government's efforts to stifle inflation and curb the black market were minimal and unsuccessful, and during his tenure the economic situation of Uganda continued its decline from Amin's rule. Many Baganda were elated by Lule's elevation to the presidency, hoping that he would preserve the Buganda region's interests and keep Obote from returning to power. Lule ultimately did take measures that pleased the Baganda, such as restoring administrative unity to Buganda, conferring more powers upon Buganda's government, frequently delivering public statements in Luganda, appointing prominent Baganda monarchists to high office, and granting some state contracts to Baganda businessmen. In redistributing properties and enterprises seized from Amin's associates, Lule's government allocated a disproportionate amount to Baganda and his close associates. Members of other ethnic groups in Uganda did not trust Lule or accord him much respect, since they felt he would promote Buganda at other regions' expense. Some Ugandans feared that his army plan would lead to the creation of a force dominated by Baganda, since Buganda had a larger population than any other region in the country. His critics denounced him as a "monarchist" and a "feudalist". Demise and removal from office Lule's handling of his cabinet provoked outrage in the NCC, especially when he dismissed Muwanga from office. President Nyerere of Tanzania informed Lule that Tanzania would uphold the agreements regarding powers among Ugandan authorities made at Moshi. Lule felt that Tanzania afforded key support to his political opponents, and thus sought to reduce its influence in the country by deprecating the standing of the TPDF, which remained after the elimination of Amin's forces to provide order. He encouraged Ugandan publications to criticise the Tanzanian army, angering some Ugandan circles and the UNLA which thought it was unfair to attack the army which had "liberated" the country. On 8 June disgruntled members of the NCC convened in Kampala and passed a resolution demanding Lule present all of his political appointments to the committee for review. Lule did not respond, so on 12 June the NCC reconvened and declared that he had seven days to comply with their demands. The President once again failed to reply, so on the afternoon of 19 June the NCC met at the Entebbe State House in Lule's presence. NCC Chairman Edward Rugumayo opened the meeting by reviewing the body's unsuccessful entreaties to the President to submit his appointments for its ratification. Lule responded by stating that he was not prepared to take a stance involving such "important constitutional matters" by agreeing to submit the appointments to the NCC. He also said that his cabinet appointments were publicly known and that the committee could "treat the appointments as you wish". Lule's statement was followed by hours of debate by the NCC concerning the division of powers agreed upon in Moshi. Later, Lule rose to say that he had not contravened the agreements made in Moshi and said that he had not received key directives supposedly dispatched to him from the NCC. Rugumayo retorted that the communications in question had been personally given to the President's secretary. Shortly after the exchange councilor Paulo Wangoola rose and delivered a long speech. He declared that Lule was not willing to accept the supremacy of UNLF governance and concluded by formally tabling a motion of no confidence in the President. This was followed by an intense debate in which different councilors gave impassioned defences and criticisms of Lule. At 1:00 on 20 June the NCC voted on the motion via secret ballot. The results were announced 35 minutes later with 18 councilors voting in favour and 14 against. Lule was thus removed from the presidency, and he walked out of the room with nine other councilors when Rugumayo said that his dismissal also triggered the removal of his cabinet. Lule held the Ugandan Presidency for just 68 days, the shortest tenure of any President of Uganda. Godfrey Binaisa, the former Attorney General of Uganda under Obote who had come to oppose both him and Amin and had no prior role in the committee, was then elected president. Binaisa retained some of Lule's ministers but removed his key supporters from the cabinet and reversed his administrative changes in Buganda. Many Baganda felt that Lule had been removed from power because he had preserved legitimate interests of Buganda. His ouster instigated large protests in Kampala and clashes between demonstrators and Tanzanian troops attempting to maintain order. Baganda protesters blocked streets and destroyed trucks while transportation workers went on strike and merchants deliberately gouged prices of basic commodities. Some armed Baganda groups formed after Lule's departure and attacked police and soldiers, rendering Buganda ungovernable. On 21 October 1980 the Ugandan Court of Appeal ruled that Lule's removal had been unlawful, stating that Lule had the authority to appoint ministers without the NCC's approval. Though the ruling technically meant Lule could still claim to be President of Uganda, most nationals chose to ignore the decision, since the political situation in the country had rapidly developed since Lule's removal. Later life Out of office, Lule was flown to Tanzania, where he was detained under armed guard before being allowed to fly to London. He later went to Nairobi, Kenya. In 1980 Uganda hosted general elections to elect a new government. In anticipation of the contest, many Baganda began to support the DP as a way of opposing Obote and the UPC. Lule planned to attend the DP's conference in June where the party would select its new leaders. The incumbent leadership feared that his Baganda support would propel him to the helm of their organisation and displace them, and thus they blocked his return to Uganda. Despite concerns of fraud and irregularities, the UPC was declared the ultimate winner of the elections and Obote became the President of Uganda. Fearful of Obote's grip on power, Lule along with others like Bernard Kibuuka Musoke founded and became head of a rebel group, the Uganda Freedom Fighters (UFF). On 8 June 1981 the UFF merged with Museveni's Popular Resistance Army to form the National Resistance Movement (NRM). Lule became chairman of the NRM, while Museveni became its vice-chairman and chairman of the High Command of the National Resistance Army, the group's armed wing. The merger greatly strengthened the support of the anti-Obote rebels in Buganda. Lule became a leading critic of Obote and authored a book, Human Rights Violations in Uganda under Obote, which was heavily circulated by non-governmental organizations. Over the last six years of his life Lule received treatment for a kidney disorder at Hammersmith Hospital in London. He died there on 21 January 1985 of kidney failure following surgery. He was buried in London. The NRM released a statement upon his death, stating that it "wishes to assure its members, supporters, sympathizers and all Ugandans that the struggle for which Professor Lule stood will continue." The NRM ultimately won the Ugandan Bush War, capturing Kampala in January 1986. Following Museveni's seizure of power, his government requested that Lule's body be repatriated. The remains were disinterred and flown to Entebbe on 22 January 1987. Greeted at the airport by large crowds, Lule's body was taken to Kampala where it lay in state for two days before being reburied in Kampala where Uganda's first national flag had been raised on its independence day. Legacy Historian Phares Mukasa Mutibwa described Lule's performance in the presidency as "amateurish". His son, Wasswa Lule, became a MP for Rubaga North. References Works cited 1912 births 1985 deaths People from Kampala Converts to Christianity from Islam Makerere University alumni University of Fort Hare alumni Presidents of Uganda Ugandan exiles Ugandan rebels Uganda National Liberation Front politicians Deaths from kidney failure People educated at King's College Budo Alumni of the University of Edinburgh Ugandan former Muslims
New Town Hall or New City Hall may refer to: Toronto City Hall New Town Hall (Bremen) New Town Hall (Hanover) New Town Hall (Leipzig) New Town Hall (Munich) New City Hall (Ostrava) New Town Hall (Prague) New Town Hall, Wiesbaden Architectural disambiguation pages
Aethalida owadai is a moth of the family Erebidae. It was described by Vladimir Viktorovitch Dubatolov and Yasunori Kishida in 2005. It is found on Selayar Island and Flores in Indonesia. Subspecies Aethalida owadai owadai Dubatolov & Kishida, 2005 (Indonesia: Selayar Island) Aethalida owadai floresiensis Spitsyn & I. Bolotov, 2016 (Indonesia: Flores) References Moths described in 2005 Spilosomina Moths of Indonesia
Don Julio is a brand of tequila produced in Mexico. It is the largest brand in value and eighth largest in volume. Its owned by the British-based multinational alcoholic beverage maker Diageo. It is distilled, manufactured and bottled by Tequila Don Julio, S.A. de C.V. from its corporate facility in the Colonia El Chichimeco district, in the city of Atotonilco El Alto, Jalisco, Mexico. History Don Julio Tequila is named after its founder, Don Julio González-Frausto Estrada, who began distilling tequila in 1942 at age 17. Acknowledging the benefits of vertical integration, Gonzalez-Frausto established his own distillery, La Primavera, and spent the next 40 years improving his craft. He experimented with controlling various aspects of the tequila-making process, "from the cultivation of the agave to the bottling of the final product." He named his distillery La Primavera (the Springtime) where he produced his first brand Tres Magueyes. He is said to have "spent nearly forty years perfecting the craft." Don Julio's first tequilas were shared with friends only, but as word on the quality of his tequila spread, he officially founded a company to put him in business. In 1983, Marco Cedano returned to Don Julio to work as an engineer, where he served as Master Distiller and Distillery Manager of Tequila. In 1985 Don Julio González-Frausto celebrated his 60th Birthday, his sons commemorated the date by creating a Tequila in his name, Don Julio. Following the sheer popularity of the tequila in Guadalajara and neighboring cities they decided to launch the tequila. In 1999 the now defunct, The Seagram Company Ltd., had invested in Tequila Don Julio, S.A. de C.V. of Mexico. The expanded agave plantations were a joint venture between the Gonzalez-Frausto, Funtanet, Andrade Rivera Torres, and Cuaik families. In 1999 Don Julio Gonzalez, delighted to forge a relationship with Seagram, stated, "I am proud that the Gonzalez-Frausto family joins with the Seagram family in a global effort behind Don Julio Tequila. I am committed to overseeing personally the agave plantations that are so vital to the superior and unique quality of the Tequila that bears my name." Diageo signed a joint venture in with Casa Cuervo in 2003, selling a 50 per cent stake in Don Julio for 78 million. It wasdistributed in the United States by Diageo, under licensing from its patent holder, Tequila Don Julio, Sociedad Anónima de Capital Variable, Jalisco, Mexico, but sold worldwide. In November 2014, Diageo agreed to a deal to take full control of the Don Julio brand. In exchange, Jose Cuervo will receive the Old Bushmills Distillery and pay Diageo $408m. Founder Don Julio Gonzalez-Frausto Estrada was born on 7 January 1925 in Atotonilco, Jalisco, where today's main facility is located. Don Julio learned the meaning of responsibility at an early age by working at his uncle José's tequila distillery. At the age of 23 he married Dorothea Garcia with whom he had 9 children. In 1942 he started a tequila distillery which would later be known as "La Primavera." By 1951, with the brand Tres Magueyes, he was on a path that would later become Tequila Don Julio in its different variants: Blanco, Reposado, Añejo, 70, 1942 and Real. Don Julio González-Frausto Estrada died on Tuesday, 20 March 2012 from natural causes. Process The agave for Don Julio's Tequila is grown in the highland area of Atotonilco on the family estate. Tequila's major aging process over time takes place in conjunction with the development of agave plants, given that they take seven years to reach maturity. Every agave plant is harvested by hand. The agave plant is cut from its roots and then the spearlike leaves are sheered off. The core that is left is called a piña, which is the raw material used for the making of tequila. The piñas are transported on a truck to Don Julio's Distillery where they are cut into equal sized pieces so that they bake evenly. The piñas are loaded into brick ovens where they are slowly baked over the course of several days. Then the baked piñas are crushed and doused with water, which releases the sweet agave syrup called agave juice. Then yeast is added to the agave water and is left to ferment. After the fermentation process is complete it results in a sweet, slight alcoholic agave beer which is then put into stills where it is distilled to become tequila. At last it is put into stainless steel tanks before bottling, or ex-bourbon casks for aging. Varieties Don Julio Blanco (available also in the US) Don Julio Reposado (available also in the US) Don Julio Añejo (available also in the US) Don Julio 70 Añejo Claro (available also in the US) Don Julio 1942 Añejo (available also in the US) Don Julio Real Extra Añejo (available also in the US) Several of these offerings have performed well at international spirit ratings competitions. For example, Don Julio's Real tequila was awarded double gold medals at the 2008 and 2011 San Francisco World Spirits Competition and a silver medal at the 2012 competition. References External links Official Website Tequila Diageo brands Alcoholic drink brands Mexican brands
```java /* * * All rights reserved. This program and the accompanying materials * * path_to_url */ package org.locationtech.jts.index.strtree; import java.io.Serializable; import java.util.ArrayList; import java.util.Collections; import java.util.Comparator; import java.util.Iterator; import java.util.List; import java.util.PriorityQueue; import org.locationtech.jts.geom.Envelope; import org.locationtech.jts.index.ItemVisitor; import org.locationtech.jts.index.SpatialIndex; import org.locationtech.jts.util.Assert; /** * A query-only R-tree created using the Sort-Tile-Recursive (STR) algorithm. * For two-dimensional spatial data. * <P> * The STR packed R-tree is simple to implement and maximizes space * utilization; that is, as many leaves as possible are filled to capacity. * Overlap between nodes is far less than in a basic R-tree. * However, the index is semi-static; once the tree has been built * (which happens automatically upon the first query), items may * not be added. * Items may be removed from the tree using {@link #remove(Envelope, Object)}. * <P> * Described in: P. Rigaux, Michel Scholl and Agnes Voisard. * <i>Spatial Databases With Application To GIS</i>. * Morgan Kaufmann, San Francisco, 2002. * <p> * <b>Note that inserting items into a tree is not thread-safe.</b> * Inserting performed on more than one thread must be synchronized externally. * <p> * Querying a tree is thread-safe. * The building phase is done synchronously, * and querying is stateless. * * @version 1.7 */ public class STRtree extends AbstractSTRtree implements SpatialIndex, Serializable { static final class STRtreeNode extends AbstractNode { STRtreeNode(int level) { super(level); } protected Object computeBounds() { Envelope bounds = null; for (Iterator i = getChildBoundables().iterator(); i.hasNext(); ) { Boundable childBoundable = (Boundable) i.next(); if (bounds == null) { bounds = new Envelope((Envelope)childBoundable.getBounds()); } else { bounds.expandToInclude((Envelope)childBoundable.getBounds()); } } return bounds; } } /** * */ private static final long serialVersionUID = 259274702368956900L; private static Comparator xComparator = new Comparator() { public int compare(Object o1, Object o2) { return compareDoubles( centreX((Envelope)((Boundable)o1).getBounds()), centreX((Envelope)((Boundable)o2).getBounds())); } }; private static Comparator yComparator = new Comparator() { public int compare(Object o1, Object o2) { return compareDoubles( centreY((Envelope)((Boundable)o1).getBounds()), centreY((Envelope)((Boundable)o2).getBounds())); } }; private static double centreX(Envelope e) { return avg(e.getMinX(), e.getMaxX()); } private static double centreY(Envelope e) { return avg(e.getMinY(), e.getMaxY()); } private static double avg(double a, double b) { return (a + b) / 2d; } private static IntersectsOp intersectsOp = new IntersectsOp() { public boolean intersects(Object aBounds, Object bBounds) { return ((Envelope)aBounds).intersects((Envelope)bBounds); } }; /** * Creates the parent level for the given child level. First, orders the items * by the x-values of the midpoints, and groups them into vertical slices. * For each slice, orders the items by the y-values of the midpoints, and * group them into runs of size M (the node capacity). For each run, creates * a new (parent) node. */ protected List createParentBoundables(List childBoundables, int newLevel) { Assert.isTrue(!childBoundables.isEmpty()); int minLeafCount = (int) Math.ceil((childBoundables.size() / (double) getNodeCapacity())); ArrayList sortedChildBoundables = new ArrayList(childBoundables); Collections.sort(sortedChildBoundables, xComparator); List[] verticalSlices = verticalSlices(sortedChildBoundables, (int) Math.ceil(Math.sqrt(minLeafCount))); return createParentBoundablesFromVerticalSlices(verticalSlices, newLevel); } private List createParentBoundablesFromVerticalSlices(List[] verticalSlices, int newLevel) { Assert.isTrue(verticalSlices.length > 0); List parentBoundables = new ArrayList(); for (int i = 0; i < verticalSlices.length; i++) { parentBoundables.addAll( createParentBoundablesFromVerticalSlice(verticalSlices[i], newLevel)); } return parentBoundables; } protected List createParentBoundablesFromVerticalSlice(List childBoundables, int newLevel) { return super.createParentBoundables(childBoundables, newLevel); } /** * @param childBoundables Must be sorted by the x-value of the envelope midpoints */ protected List[] verticalSlices(List childBoundables, int sliceCount) { int sliceCapacity = (int) Math.ceil(childBoundables.size() / (double) sliceCount); List[] slices = new List[sliceCount]; Iterator i = childBoundables.iterator(); for (int j = 0; j < sliceCount; j++) { slices[j] = new ArrayList(); int boundablesAddedToSlice = 0; while (i.hasNext() && boundablesAddedToSlice < sliceCapacity) { Boundable childBoundable = (Boundable) i.next(); slices[j].add(childBoundable); boundablesAddedToSlice++; } } return slices; } private static final int DEFAULT_NODE_CAPACITY = 10; /** * Constructs an STRtree with the default node capacity. */ public STRtree() { this(DEFAULT_NODE_CAPACITY); } /** * Constructs an STRtree with the given maximum number of child nodes that * a node may have. * <p> * The minimum recommended capacity setting is 4. * */ public STRtree(int nodeCapacity) { super(nodeCapacity); } /** * Constructs an STRtree with the given maximum number of child nodes that * a node may have, and the root that links to all other nodes * <p> * The minimum recommended capacity setting is 4. * */ public STRtree(int nodeCapacity, STRtreeNode root) { super(nodeCapacity, root); } /** * Constructs an STRtree with the given maximum number of child nodes that * a node may have, and all leaf nodes in the tree * <p> * The minimum recommended capacity setting is 4. * */ public STRtree(int nodeCapacity, ArrayList itemBoundables) { super(nodeCapacity, itemBoundables); } protected AbstractNode createNode(int level) { return new STRtreeNode(level); } protected IntersectsOp getIntersectsOp() { return intersectsOp; } /** * Inserts an item having the given bounds into the tree. */ public void insert(Envelope itemEnv, Object item) { if (itemEnv.isNull()) { return; } super.insert(itemEnv, item); } /** * Returns items whose bounds intersect the given envelope. */ public List query(Envelope searchEnv) { //Yes this method does something. It specifies that the bounds is an //Envelope. super.query takes an Object, not an Envelope. [Jon Aquino 10/24/2003] return super.query((Object)searchEnv); } /** * Returns items whose bounds intersect the given envelope. */ public void query(Envelope searchEnv, ItemVisitor visitor) { //Yes this method does something. It specifies that the bounds is an //Envelope. super.query takes an Object, not an Envelope. [Jon Aquino 10/24/2003] super.query(searchEnv, visitor); } /** * Removes a single item from the tree. * * @param itemEnv the Envelope of the item to remove * @param item the item to remove * @return <code>true</code> if the item was found */ public boolean remove(Envelope itemEnv, Object item) { return super.remove(itemEnv, item); } /** * Returns the number of items in the tree. * * @return the number of items in the tree */ public int size() { return super.size(); } /** * Returns the number of levels in the tree. * * @return the number of levels in the tree */ public int depth() { return super.depth(); } protected Comparator getComparator() { return yComparator; } /** * Finds the two nearest items in the tree, * using {@link ItemDistance} as the distance metric. * A Branch-and-Bound tree traversal algorithm is used * to provide an efficient search. * <p> * If the tree is empty, the return value is <code>null</code. * If the tree contains only one item, * the return value is a pair containing that item. * <b> * If it is required to find only pairs of distinct items, * the {@link ItemDistance} function must be <b>anti-reflexive</b>. * * @param itemDist a distance metric applicable to the items in this tree * @return the pair of the nearest items * or <code>null</code> if the tree is empty */ public Object[] nearestNeighbour(ItemDistance itemDist) { if (isEmpty()) return null; // if tree has only one item this will return null BoundablePair bp = new BoundablePair(this.getRoot(), this.getRoot(), itemDist); return nearestNeighbour(bp); } /** * Finds the item in this tree which is nearest to the given {@link Object}, * using {@link ItemDistance} as the distance metric. * A Branch-and-Bound tree traversal algorithm is used * to provide an efficient search. * <p> * The query <tt>object</tt> does <b>not</b> have to be * contained in the tree, but it does * have to be compatible with the <tt>itemDist</tt> * distance metric. * * @param env the envelope of the query item * @param item the item to find the nearest neighbour of * @param itemDist a distance metric applicable to the items in this tree and the query item * @return the nearest item in this tree * or <code>null</code> if the tree is empty */ public Object nearestNeighbour(Envelope env, Object item, ItemDistance itemDist) { if (isEmpty()) return null; Boundable bnd = new ItemBoundable(env, item); BoundablePair bp = new BoundablePair(this.getRoot(), bnd, itemDist); return nearestNeighbour(bp)[0]; } /** * Finds the two nearest items from this tree * and another tree, * using {@link ItemDistance} as the distance metric. * A Branch-and-Bound tree traversal algorithm is used * to provide an efficient search. * The result value is a pair of items, * the first from this tree and the second * from the argument tree. * * @param tree another tree * @param itemDist a distance metric applicable to the items in the trees * @return the pair of the nearest items, one from each tree * or <code>null</code> if no pair of distinct items can be found */ public Object[] nearestNeighbour(STRtree tree, ItemDistance itemDist) { if (isEmpty() || tree.isEmpty()) return null; BoundablePair bp = new BoundablePair(this.getRoot(), tree.getRoot(), itemDist); return nearestNeighbour(bp); } private Object[] nearestNeighbour(BoundablePair initBndPair) { double distanceLowerBound = Double.POSITIVE_INFINITY; BoundablePair minPair = null; // initialize search queue PriorityQueue priQ = new PriorityQueue(); priQ.add(initBndPair); while (! priQ.isEmpty() && distanceLowerBound > 0.0) { // pop head of queue and expand one side of pair BoundablePair bndPair = (BoundablePair) priQ.poll(); double pairDistance = bndPair.getDistance(); /** * If the distance for the first pair in the queue * is >= current minimum distance, other nodes * in the queue must also have a greater distance. * So the current minDistance must be the true minimum, * and we are done. */ if (pairDistance >= distanceLowerBound) break; /** * If the pair members are leaves * then their distance is the exact lower bound. * Update the distanceLowerBound to reflect this * (which must be smaller, due to the test * immediately prior to this). */ if (bndPair.isLeaves()) { // assert: currentDistance < minimumDistanceFound distanceLowerBound = pairDistance; minPair = bndPair; } else { /** * Otherwise, expand one side of the pair, * and insert the expanded pairs into the queue. * The choice of which side to expand is determined heuristically. */ bndPair.expandToQueue(priQ, distanceLowerBound); } } if (minPair == null) return null; // done - return items with min distance return new Object[] { ((ItemBoundable) minPair.getBoundable(0)).getItem(), ((ItemBoundable) minPair.getBoundable(1)).getItem() }; } /** * Tests whether some two items from this tree and another tree * lie within a given distance. * {@link ItemDistance} is used as the distance metric. * A Branch-and-Bound tree traversal algorithm is used * to provide an efficient search. * * @param tree another tree * @param itemDist a distance metric applicable to the items in the trees * @param maxDistance the distance limit for the search * @return true if there are items within the distance */ public boolean isWithinDistance(STRtree tree, ItemDistance itemDist, double maxDistance) { BoundablePair bp = new BoundablePair(this.getRoot(), tree.getRoot(), itemDist); return isWithinDistance(bp, maxDistance); } /** * Performs a withinDistance search on the tree node pairs. * This is a different search algorithm to nearest neighbour. * It can utilize the {@link BoundablePair#maximumDistance()} between * tree nodes to confirm if two internal nodes must * have items closer than the maxDistance, * and short-circuit the search. * * @param initBndPair the initial pair containing the tree root nodes * @param maxDistance the maximum distance to search for * @return true if two items lie within the given distance */ private boolean isWithinDistance(BoundablePair initBndPair, double maxDistance) { double distanceUpperBound = Double.POSITIVE_INFINITY; // initialize search queue PriorityQueue priQ = new PriorityQueue(); priQ.add(initBndPair); while (! priQ.isEmpty()) { // pop head of queue and expand one side of pair BoundablePair bndPair = (BoundablePair) priQ.poll(); double pairDistance = bndPair.getDistance(); /** * If the distance for the first pair in the queue * is > maxDistance, all other pairs * in the queue must have a greater distance as well. * So can conclude no items are within the distance * and terminate with result = false */ if (pairDistance > maxDistance) return false; /** * If the maximum distance between the nodes * is less than the maxDistance, * than all items in the nodes must be * closer than the max distance. * Then can terminate with result = true. * * NOTE: using Envelope MinMaxDistance * would provide a tighter bound, * but not much performance improvement has been observed */ if (bndPair.maximumDistance() <= maxDistance) return true; /** * If the pair items are leaves * then their actual distance is an upper bound. * Update the distanceUpperBound to reflect this */ if (bndPair.isLeaves()) { // assert: currentDistance < minimumDistanceFound distanceUpperBound = pairDistance; /** * If the items are closer than maxDistance * can terminate with result = true. */ if (distanceUpperBound <= maxDistance) return true; } else { /** * Otherwise, expand one side of the pair, * and insert the expanded pairs into the queue. * The choice of which side to expand is determined heuristically. */ bndPair.expandToQueue(priQ, distanceUpperBound); } } return false; } /** * Finds up to k items in this tree which are the nearest neighbors to the given {@code item}, * using {@code itemDist} as the distance metric. * A Branch-and-Bound tree traversal algorithm is used * to provide an efficient search. * This method implements the KNN algorithm described in the following paper: * <p> * Roussopoulos, Nick, Stephen Kelley, and Frdric Vincent. "Nearest neighbor queries." * ACM sigmod record. Vol. 24. No. 2. ACM, 1995. * <p> * The query {@code item} does <b>not</b> have to be * contained in the tree, but it does * have to be compatible with the {@code itemDist} * distance metric. * <p> * If the tree size is smaller than k fewer items will be returned. * If the tree is empty an array of size 0 is returned. * * @param env the envelope of the query item * @param item the item to find the nearest neighbours of * @param itemDist a distance metric applicable to the items in this tree and the query item * @param k the maximum number of nearest items to search for * @return an array of the nearest items found (with length between 0 and K) */ public Object[] nearestNeighbour(Envelope env, Object item, ItemDistance itemDist,int k) { if (isEmpty()) return new Object[0]; Boundable bnd = new ItemBoundable(env, item); BoundablePair bp = new BoundablePair(this.getRoot(), bnd, itemDist); return nearestNeighbourK(bp,k); } private Object[] nearestNeighbourK(BoundablePair initBndPair, int k) { return nearestNeighbourK(initBndPair, Double.POSITIVE_INFINITY,k); } private Object[] nearestNeighbourK(BoundablePair initBndPair, double maxDistance, int k) { double distanceLowerBound = maxDistance; // initialize internal structures PriorityQueue priQ = new PriorityQueue(); // initialize queue priQ.add(initBndPair); PriorityQueue kNearestNeighbors = new PriorityQueue(); while (! priQ.isEmpty() && distanceLowerBound >= 0.0) { // pop head of queue and expand one side of pair BoundablePair bndPair = (BoundablePair) priQ.poll(); double pairDistance = bndPair.getDistance(); /** * If the distance for the first node in the queue * is >= the current maximum distance in the k queue , all other nodes * in the queue must also have a greater distance. * So the current minDistance must be the true minimum, * and we are done. */ if (pairDistance >= distanceLowerBound){ break; } /** * If the pair members are leaves * then their distance is the exact lower bound. * Update the distanceLowerBound to reflect this * (which must be smaller, due to the test * immediately prior to this). */ if (bndPair.isLeaves()) { // assert: currentDistance < minimumDistanceFound if(kNearestNeighbors.size()<k){ kNearestNeighbors.add(bndPair); } else { BoundablePair bp1 = (BoundablePair) kNearestNeighbors.peek(); if(bp1.getDistance() > pairDistance) { kNearestNeighbors.poll(); kNearestNeighbors.add(bndPair); } /* * minDistance should be the farthest point in the K nearest neighbor queue. */ BoundablePair bp2 = (BoundablePair) kNearestNeighbors.peek(); distanceLowerBound = bp2.getDistance(); } } else { /** * Otherwise, expand one side of the pair, * (the choice of which side to expand is heuristically determined) * and insert the new expanded pairs into the queue */ bndPair.expandToQueue(priQ, distanceLowerBound); } } // done - return items with min distance return getItems(kNearestNeighbors); } private static Object[] getItems(PriorityQueue kNearestNeighbors) { /** * Iterate the K Nearest Neighbour Queue and retrieve the item from each BoundablePair * in this queue */ Object[] items = new Object[kNearestNeighbors.size()]; int count=0; while( ! kNearestNeighbors.isEmpty() ) { BoundablePair bp = (BoundablePair) kNearestNeighbors.poll(); items[count]=((ItemBoundable)bp.getBoundable(0)).getItem(); count++; } return items; } } ```
is the fourth studio album by Japanese idol duo Wink, released by Polystar on July 11, 1990. It features the No. 1 single "Sexy Music", a Japanese-language cover of The Nolans' 1981 single. Also included in the album are covers of Carmin's "Dos Hombres", the Nolans' "I'm in the Mood for Dancing", Kool & the Gang's "Cherish", and Eddie Hodges' "I'm Gonna Knock on Your Door". Velvet was Wink's first album to feature Satoshi Kadokura as the duo's music arranger. The album peaked at No. 4 on Oricon's albums chart and sold over 198,000 copies. It was also certified Gold by the RIAJ. Track listing All lyrics are written by Neko Oikawa, except where indicated; all music is arranged by Satoshi Kadokura, except where indicated. Charts Certification References External links 1990 albums Wink (duo) albums Japanese-language albums
Troy Newman may refer to: Troy Newman (activist), American anti-abortion activist Troy Newman (singer), Australian singer-songwriter and musician
The Ministry of the Environment and Natural Resources (MARENA), is in charge of environmental protection and of the study, planning, and management of the Nicaragua's natural resources. It was formerly known as the Nicaraguan Institute of Natural Resources and the Environment (IRENA). The ministry was created in 1979 by the Government of Nicaragua . Origins In 1976, a group of Nicaraguan environmentalists proposed that the government create a Ministry of Natural Resources. The president at the time, Anastasio Somoza Debayle, rejected the idea and threatened the group with harsh reprisals if they met again. Some took to the forests and mountains to join the Sandinista guerrillas who were fomenting revolution against the Somoza government. Less than a week after the Somoza regime was overthrown and Sandinista government became known as MARENA. By the mid-1980s, MARENA received aid and advice from Sweden, Norway, Denmark, the Soviet Union, France, the Netherlands, Cuba, Mexico, the Organization of American States, the United Nations Environment Programme, and individual United States citizens. Overview MARENA initiates and manages programs in reforestation, watershed management, pollution control, wildlife conservation, national parks, and the conservation of genetic diversity. In 1981, MARENA found that half of water sources they sampled were seriously polluted by sewage and that 70,000 pounds of raw sewage was released into Lake Managua each day. Scores of industrial plants located on the lake's shore had freely dumped there for over a decade. The worst polluter was Pennwalt Corporation. MARENA could not afford, however, to build a sewage treatment plant because of the financial costs involved. Recently a treatment plant has been completed and the sewer network is being constructed. In 1982, MARENA established seasonal hunting bans for 26 endangered species of mammals and 4 species of reptiles. This was in response to Nicaragua being a world leader in the export of rare and endangered species such as White-lipped peccaries, White-tailed deer, hawksbill turtles, freshwater otters, jaguars, ocelots, and margays. Educational campaigns were initiated by MARENA, along with marketplace and roadside inspections. By 1985, however, many of these bans were lifted because of the growing economic crisis in the country. In 1983, MARENA targeted nearly one-fifth of Nicaragua's territory for national parks. This project was never realized, however, because the Contras had militarized much of the wilderness. To address deforestation, MARENA directed major tree planting projects. Two million trees were grown annually in nurseries until 1986, when civil war and economic difficulties slowed the program. The reforestation projects became targets for the Contras, who sabotaged projects, and kidnapped and murdered over 50 MARENA employees. See also Protected areas of Nicaragua Wildlife of Nicaragua National System of Protected Areas (Nicaragua) References External links MARENA - government website History of Nicaragua Nature conservation in Nicaragua Forestry in Nicaragua Deforestation Nicaragua Nicaragua Environment of Nicaragua Nicaragua Environment Nicaragua
```python # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # # path_to_url # # Unless required by applicable law or agreed to in writing, # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY # specific language governing permissions and limitations # pylint: disable=invalid-name """Hexagon slice relu op""" from tvm import te, tir, topi from ..utils import get_layout_transform_fn def relu_compute(Input): """Relu topi compute""" return topi.nn.relu(Input) def relu_te_sched(Output, Input, layout): """ Schedule assumes the layout function to be bijective """ s = te.create_schedule(Output.op) s[Input].transform_layout(layout) out_axes = s[Output].transform_layout(layout) fused = s[Output].fuse(out_axes[6], out_axes[7]) s[Output].vectorize(fused) return s def relu_stir_schedule(Input, Output, input_layout, output_layout): """ Schedule assumes the layout function to be bijective """ if (input_layout != output_layout) or (output_layout != "nhwc-8h2w32c2w-2d"): raise RuntimeError( f"Unexpected input_layout, output_layout '{input_layout, output_layout}'" ) relu_func = te.create_prim_func([Input, Output]) sch = tir.Schedule(relu_func, debug_mask="all") block = sch.get_block("compute") sch.transform_layout(block, Input.name, get_layout_transform_fn(input_layout)) sch.transform_layout(block, Output.name, get_layout_transform_fn(output_layout)) n, h, w, c = sch.get_loops(block) h_o, h_i = sch.split(h, [None, 8]) w_o, w_i = sch.split(w, [None, 4]) c_o, c_i = sch.split(c, [None, 32]) wio, wii = sch.split(w_i, [None, 2]) sch.reorder(n, h_o, w_o, c_o, h_i, wio, c_i, wii) fused = sch.fuse(c_i, wii) sch.vectorize(fused) return sch ```
Nolubabalo Ndzundzu (born 21 December 1977) is a South African former cricketer who played as a right-arm medium bowler. She appeared in one Test match and 16 One Day Internationals for South Africa between 2000 and 2005. She played domestic cricket for Border. Ndzundzu was the first black woman to play cricket for South Africa. In July 2021, she told a Social Justice and Nation-Building hearing convened by Cricket South Africa that she had faced humiliation and discrimination during her international career. On tours, other members of the national team had wanted to change rooms if they were roomed with her, and had laughed at her poor command of English. After Ndzundzu retired as a cricketer, she became a police officer, and, subsequently, the selection convenor for the Border women's cricket team. References External links 1977 births Living people Cricketers from Qonce South African women cricketers South Africa women Test cricketers South Africa women One Day International cricketers Border women cricketers
The dalca or piragua is a type of canoe employed by the Chonos, a nomadic indigenous people of southern Chile, and Huilliche people living in Chiloé archipelago. It was a light boat and ideal for navigating local waterways, including between islands of the Chiloé Archipelago, through the Chacao Channel to mainland Chile, and along the coast of the Gulf of Penas. Spanish chronicles called it best-suited for those waters, far superior to ships of the conquistadores. The dalca was essential for many activities in Chiloé Archipelago including the logging of alerce wood, the Circular Mission system, and the various expeditions to Nahuel Huapi Lake and the channels of Patagonia. By 1886 dalcas had been replaced by other boat types and were not longer in use in Chiloé. According to archaeologist José Miguel Ramírez, only full non-reconstructed dalcas remaining were collected by Swedish explorer Carl Skottsberg and are at the Museum of Ethnography, Stockholm and the Museum of World Culture, Gothenburg. See also Antonio de Vea expedition Maritime history of Chile References Further reading Garcia, Jose (1889). "Travel Diary i navigation made by Father José Garcia of the Company of Jesus from its mission of Cailã n, in Chiloe, toward the south, in the years 1766-1767 ". Hydrographic Yearbook of the Chilean Navy. Took 14 Valparaiso : Hydrographic Institute of the Chilean Navy. pp. 3–42. Cárdenas, Renato. Dante Montiel and Catherine Hall (1991). The Chono and the regattas of Chiloé. Santiago, Chile: Olimpho. Edwards, Clinton R (1965) "Aboriginal Watercraft on the Pacific Coast of South America." University of California Press, Berkeley and Los Angeles. Canoes Mapuche culture Indigenous culture of the Southern Cone Chiloé Archipelago Aysén Region Maritime history of Chile
Waushara County is a county located in the U.S. state of Wisconsin. As of the 2020 census, the population was 24,520. Its county seat is Wautoma. Waushara County is located in central Wisconsin, about north of Madison. History Waushara County was established by an act of the Wisconsin Legislature on February 15, 1851. It originally consisted of a single organized Town of Waushara. In 1852 the county achieved full organization. The county seat was first located at Sacramento and was relocated to Wautoma in 1854 after a bitter fight between proponents of the two places. The name is of Ho-Chunk origin and is believed to mean "good land". Geography According to the U.S. Census Bureau, the county has a total area of , of which is land and (1.8%) is water. Major highways Interstate 39 U.S. Highway 51 Highway 21 (Wisconsin) Highway 22 (Wisconsin) Highway 49 (Wisconsin) Highway 73 (Wisconsin) Buses List of intercity bus stops in Wisconsin Airports Wautoma Municipal Airport serves Waushara County and the surrounding communities Wild Rose Idlewild Airport also serves Waushara County and the surrounding communities Adjacent counties Portage County - north Waupaca County - northeast Winnebago County - east Green Lake County - south Marquette County - south Adams County - west Climate Demographics 2020 census As of the census of 2020, the population was 24,520. The population density was . There were 14,710 housing units at an average density of . The racial makeup of the county was 89.9% White, 1.6% Black or African American, 0.6% Native American, 0.4% Asian, 0.1% Pacific Islander, 2.8% from other races, and 4.6% from two or more races. Ethnically, the population was 6.9% Hispanic or Latino of any race. 2000 census As of the census of 2000, there were 23,154 people, 9,336 households, and 6,581 families residing in the county. The population density was . There were 13,667 housing units at an average density of . The racial makeup of the county was 96.80% White, 0.27% Black or African American, 0.31% Native American, 0.35% Asian, 0.03% Pacific Islander, 1.36% from other races, and 0.89% from two or more races. 3.66% of the population were Hispanic or Latino of any race. 47.5% were of German, 9.1% Polish, 5.9% Irish, 5.7% American and 5.6% English ancestry. 94.5% spoke English, 3.4% Spanish and 1.4% German as their first language. There were 9,336 households, out of which 27.60% had children under the age of 18 living with them, 60.00% were married couples living together, 6.70% had a female householder with no husband present, and 29.50% were non-families. 24.90% of all households were made up of individuals, and 11.90% had someone living alone who was 65 years of age or older. The average household size was 2.43 and the average family size was 2.89. In the county, the population was spread out, with 23.50% under the age of 18, 6.00% from 18 to 24, 24.90% from 25 to 44, 26.30% from 45 to 64, and 19.20% who were 65 years of age or older. The median age was 42 years. For every 100 females there were 101.60 males. For every 100 females age 18 and over, there were 98.80 males. In 2017, there were 222 births, giving a general fertility rate of 67.3 births per 1000 women aged 15–44, the 22nd highest rate out of all 72 Wisconsin counties. Of these, 19 of the births occurred at home. Additionally, there were 10 reported induced abortions performed on women of Waushara County residence in 2017. Communities Cities Berlin (mostly in Green Lake County) Wautoma (county seat) Villages Coloma Hancock Lohrville Plainfield Redgranite Wild Rose Towns Aurora Bloomfield Coloma Dakota Deerfield Hancock Leon Marion Mount Morris Oasis Plainfield Poy Sippi Richford Rose Saxeville Springwater Warren Wautoma Census-designated places Pine River Poy Sippi Tustin Unincorporated communities Auroraville Bannerman Borth Brushville Dakota Fountain Valley Heffron (partially) Metz (partial) Mount Morris Richford Saxeville Silver Lake Spring Lake West Bloomfield Ghost towns Rodney Politics Waushara County has long been one of the most Republican counties in Wisconsin. Only three Democrats have carried the county at a presidential level since the formation of the Republican Party – Franklin D. Roosevelt in 1932, Bill Clinton in 1996, and Barack Obama in 2008 – of whom only Roosevelt won an absolute majority. In 1936, when Roosevelt carried Wisconsin by a two-to-one majority, Alf Landon won Waushara County by double digits, while it was one of only three Wisconsin counties, alongside Walworth and Waupaca, to vote for Barry Goldwater over Lyndon Johnson in 1964. It has voted Republican since 2012. In other statewide races, the county is equally Republican. Waushara County has never backed a Democrat for Governor since before 1900. Senators Herb Kohl in 2006 and William Proxmire in 1976 and 1970 did carry Waushara County when they swept every county in the state, but no other Democratic senatorial candidate has won the county since the Seventeenth Amendment. See also National Register of Historic Places listings in Waushara County, Wisconsin References Further reading Portrait and Biographical Album of Green Lake, Marquette and Waushara Counties, Wisconsin. Chicago: Acme Publishing, 1890. External links Waushara County website Waushara County map from the Wisconsin Department of Transportation 1852 establishments in Wisconsin Populated places established in 1852
Lloyd Edward Cotsen (1929–2017) was an American businessman. Early life and family Cotsen was born in Boston on February 25, 1929, to Lloyd Edward Cotsen Sr. and Sophie Cotsen. He obtained a bachelor's degree in history from Princeton University before serving in the U.S. Navy. He later returned to Princeton to study architecture and participated in a prehistoric excavation in Greece as a field architect. His first wife, Joanne Stolaroff, was murdered along with their 13-year-old son, Noah in Beverly Hills in 1979. Cotsen's second marriage, to Jacqueline Brandwynne, ended in divorce. He is survived by his third wife, Margit Sperling, two daughters and a son. Career After completing an MBA from Harvard Business School, Cotsen joined Natone, a cosmetics supply company founded by his father-in-law, Emanuel Stolaroff. Natone would later be renamed Neutrogena. Cotsen played his role in the rise of the company's amber-colored glycerin soap. He held multiple leadership positions within the company, including president (1967), became the CEO in 1973, and the chairman in 1991. He sold Neutrogena in 1994, with the shares he controlled amounting to almost $350 million before taxes. After his retirement, Cotsen dedicated his time to collecting contemporary textile fragments, Japanese ceramics, and turned wood. At the time of his death on May 8, 2017, in Beverly Hills, California, Cotsen had donated approximately half of his collection to institutions such as the Asian Art Museum in San Francisco, Princeton University, and the Museum of International Folk Art. He was a major donor of the University of California, Los Angeles's Cotsen Institute of Archaeology, which was renamed in his honor in 1999. References 1929 births 2017 deaths 20th-century American businesspeople Princeton University alumni Harvard Business School alumni
Dr. William Tyznik (April 26, 1927 – May 3, 2013) was a professor of the department of Animal Science at Ohio State University where he taught for over 40 years. Tyznik invented Frosty Paws, a frozen treat for dogs, and TizWhiz animal feed. Education He attended the University of Wisconsin, College of Agriculture, and received his Bachelor's (1948), Master's (1949) and Ph.D. (1951) degrees. References 1927 births 2013 deaths Ohio State University faculty American zoologists University of Wisconsin–Madison College of Agricultural and Life Sciences alumni
```python #!/usr/bin/env python3 # # import struct import sys from packaging import version import elftools from elftools.elf.elffile import ELFFile from elftools.elf.sections import SymbolTableSection if version.parse(elftools.__version__) < version.parse('0.24'): sys.exit("pyelftools is out of date, need version 0.24 or later") class _Symbol: """ Parent class for objects derived from an elf symbol. """ def __init__(self, elf, sym): self.elf = elf self.sym = sym self.data = self.elf.symbol_data(sym) def __lt__(self, other): return self.sym.entry.st_value < other.sym.entry.st_value def _data_native_read(self, offset): (format, size) = self.elf.native_struct_format return struct.unpack(format, self.data[offset:offset + size])[0] class DevicePM(_Symbol): """ Represents information about device PM capabilities. """ required_ld_consts = [ "_PM_DEVICE_STRUCT_FLAGS_OFFSET", "_PM_DEVICE_FLAG_PD" ] def __init__(self, elf, sym): super().__init__(elf, sym) self.flags = self._data_native_read(self.elf.ld_consts['_PM_DEVICE_STRUCT_FLAGS_OFFSET']) @property def is_power_domain(self): return self.flags & (1 << self.elf.ld_consts["_PM_DEVICE_FLAG_PD"]) class DeviceOrdinals(_Symbol): """ Represents information about device dependencies. """ DEVICE_HANDLE_SEP = -32768 DEVICE_HANDLE_ENDS = 32767 DEVICE_HANDLE_NULL = 0 def __init__(self, elf, sym): super().__init__(elf, sym) format = "<" if self.elf.little_endian else ">" format += "{:d}h".format(len(self.data) // 2) self._ordinals = struct.unpack(format, self.data) self._ordinals_split = [] # Split ordinals on DEVICE_HANDLE_SEP prev = 1 for idx, val in enumerate(self._ordinals, 1): if val == self.DEVICE_HANDLE_SEP: self._ordinals_split.append(self._ordinals[prev:idx-1]) prev = idx self._ordinals_split.append(self._ordinals[prev:]) @property def self_ordinal(self): return self._ordinals[0] @property def ordinals(self): return self._ordinals_split class Device(_Symbol): """ Represents information about a device object and its references to other objects. """ required_ld_consts = [ "_DEVICE_STRUCT_HANDLES_OFFSET", "_DEVICE_STRUCT_PM_OFFSET" ] def __init__(self, elf, sym): super().__init__(elf, sym) self.edt_node = None self.handle = None self.ordinals = None self.pm = None # Devicetree dependencies, injected dependencies, supported devices self.devs_depends_on = set() self.devs_depends_on_injected = set() self.devs_supports = set() # Point to the handles instance associated with the device; # assigned by correlating the device struct handles pointer # value with the addr of a Handles instance. self.obj_ordinals = None if '_DEVICE_STRUCT_HANDLES_OFFSET' in self.elf.ld_consts: ordinal_offset = self.elf.ld_consts['_DEVICE_STRUCT_HANDLES_OFFSET'] self.obj_ordinals = self._data_native_read(ordinal_offset) self.obj_pm = None if '_DEVICE_STRUCT_PM_OFFSET' in self.elf.ld_consts: pm_offset = self.elf.ld_consts['_DEVICE_STRUCT_PM_OFFSET'] self.obj_pm = self._data_native_read(pm_offset) @property def ordinal(self): return self.ordinals.self_ordinal class ZephyrElf: """ Represents information about devices in an elf file. """ def __init__(self, kernel, edt, device_start_symbol): self.elf = ELFFile(open(kernel, "rb")) self.relocatable = self.elf['e_type'] == 'ET_REL' self.edt = edt self.devices = [] self.ld_consts = self._symbols_find_value(set([device_start_symbol, *Device.required_ld_consts, *DevicePM.required_ld_consts])) self._device_parse_and_link() @property def little_endian(self): """ True if the elf file is for a little-endian architecture. """ return self.elf.little_endian @property def native_struct_format(self): """ Get the struct format specifier and byte size of the native machine type. """ format = "<" if self.little_endian else ">" if self.elf.elfclass == 32: format += "I" size = 4 else: format += "Q" size = 8 return (format, size) def symbol_data(self, sym): """ Retrieve the raw bytes associated with a symbol from the elf file. """ # Symbol data parameters addr = sym.entry.st_value length = sym.entry.st_size # Section associated with the symbol section = self.elf.get_section(sym.entry['st_shndx']) data = section.data() # Relocatable data does not appear to be shifted offset = addr - (0 if self.relocatable else section['sh_addr']) # Validate data extraction assert offset + length <= len(data) # Extract symbol bytes from section return bytes(data[offset:offset + length]) def _symbols_find_value(self, names): symbols = {} for section in self.elf.iter_sections(): if isinstance(section, SymbolTableSection): for sym in section.iter_symbols(): if sym.name in names: symbols[sym.name] = sym.entry.st_value return symbols def _object_find_named(self, prefix, cb): for section in self.elf.iter_sections(): if isinstance(section, SymbolTableSection): for sym in section.iter_symbols(): if sym.entry.st_info.type != 'STT_OBJECT': continue if sym.name.startswith(prefix): cb(sym) def _link_devices(self, devices): # Compute the dependency graph induced from the full graph restricted to the # the nodes that exist in the application. Note that the edges in the # induced graph correspond to paths in the full graph. root = self.edt.dep_ord2node[0] for ord, dev in devices.items(): n = self.edt.dep_ord2node[ord] deps = set(n.depends_on) while len(deps) > 0: dn = deps.pop() if dn.dep_ordinal in devices: # this is used dev.devs_depends_on.add(devices[dn.dep_ordinal]) elif dn != root: # forward the dependency up one level for ddn in dn.depends_on: deps.add(ddn) sups = set(n.required_by) while len(sups) > 0: sn = sups.pop() if sn.dep_ordinal in devices: dev.devs_supports.add(devices[sn.dep_ordinal]) else: # forward the support down one level for ssn in sn.required_by: sups.add(ssn) def _link_injected(self, devices): for dev in devices.values(): injected = dev.ordinals.ordinals[1] for inj in injected: if inj in devices: dev.devs_depends_on_injected.add(devices[inj]) devices[inj].devs_supports.add(dev) def _device_parse_and_link(self): # Find all PM structs pm_structs = {} def _on_pm(sym): pm_structs[sym.entry.st_value] = DevicePM(self, sym) self._object_find_named('__pm_device_', _on_pm) # Find all ordinal arrays ordinal_arrays = {} def _on_ordinal(sym): ordinal_arrays[sym.entry.st_value] = DeviceOrdinals(self, sym) self._object_find_named('__devicedeps_', _on_ordinal) # Find all device structs def _on_device(sym): self.devices.append(Device(self, sym)) self._object_find_named('__device_', _on_device) # Sort the device array by address (st_value) for handle calculation self.devices = sorted(self.devices) # Assign handles to the devices for idx, dev in enumerate(self.devices): dev.handle = 1 + idx # Link devices structs with PM and ordinals for dev in self.devices: if dev.obj_pm in pm_structs: dev.pm = pm_structs[dev.obj_pm] if dev.obj_ordinals in ordinal_arrays: dev.ordinals = ordinal_arrays[dev.obj_ordinals] if dev.ordinal != DeviceOrdinals.DEVICE_HANDLE_NULL: dev.edt_node = self.edt.dep_ord2node[dev.ordinal] # Create mapping of ordinals to devices devices_by_ord = {d.ordinal: d for d in self.devices if d.edt_node} # Link devices to each other based on the EDT tree self._link_devices(devices_by_ord) # Link injected devices to each other self._link_injected(devices_by_ord) def device_dependency_graph(self, title, comment): """ Construct a graphviz Digraph of the relationships between devices. """ import graphviz dot = graphviz.Digraph(title, comment=comment) # Split iteration so nodes and edges are grouped in source for dev in self.devices: if dev.ordinal == DeviceOrdinals.DEVICE_HANDLE_NULL: text = '{:s}\\nHandle: {:d}'.format(dev.sym.name, dev.handle) else: n = self.edt.dep_ord2node[dev.ordinal] text = '{:s}\\nOrdinal: {:d} | Handle: {:d}\\n{:s}'.format( n.name, dev.ordinal, dev.handle, n.path ) dot.node(str(dev.ordinal), text) for dev in self.devices: for sup in sorted(dev.devs_supports): dot.edge(str(dev.ordinal), str(sup.ordinal)) return dot ```
A Thousand Times Good Night () is an Irish-Norwegian produced English language 2013 drama film directed by Erik Poppe and starring Juliette Binoche, Nikolaj Coster-Waldau, Maria Doyle Kennedy, Larry Mullen Jr. and Mads Ousdal. Plot Rebecca (Binoche) is a photo journalist obsessed with reporting in dangerous war zones. Documenting a group of female suicide bombers in Afghanistan, she accompanies one of them to Kabul, where the premature detonation of the bomb severely injures her. While recuperating at her home in Ireland, Rebecca is confronted by her husband Marcus (Coster-Waldau) and her daughter Steph (Lauryn Canny), who force her to choose between covering war zones, or her family. She chooses her family. Steph is intrigued by her mother's photographs and interested in humanitarian work in Africa, so Rebecca proposes a photography trip with her daughter to a refugee camp in Kenya. Marcus agrees, assuming that the trip will be safe. Instead, the camp is attacked by an armed group that begins murdering people in their tents. Rebecca sends her daughter to safety, but stays in the camp to document the attack. Upon their return, Steph and Rebecca don't tell her father, but he finds out. He angrily throws Rebecca out, and doesn't allow her to see the girls. Just before getting on a plane for Kabul, Rebecca gets a voicemail reminder from Steph of her presentation at school of their trip. With it, she lets her mother know she understands the importance of her work. Rebecca does not board the plane and goes to the presentation. That night, Rebecca is allowed to tuck the girls in. The next day, she's again in Kabul, documenting the outfitting of another suicide bomber; this time a young girl. It affects her much more than the previous time. She breaks down and the camera fades to black. Production Autobiographical elements in the film come from Poppe's work as a photo journalist in the 1980s, covering conflicts in Central America, the Middle East, Africa and Southeast Asia. Most of the film was shot in Ireland and Morocco. Funding was provided by the Irish Film Board and Norsk Filminstitutt. The film was produced by Finn Gjerdrum and Stein Kvae, while John Christian Rosenlund was lead photographer. A number of war-zone still images by photographers Marcus Bleasdale and Astrid Sehl, play an important role in the film. Critical reception The Hollywood Reporter called the film an "affecting drama made more poignant by honest-feeling autobiographical elements" and praised Binoche's "complex performance" as "deserving particular attention." Variety called the film a "gripping tale of a dedicated photojournalist torn between passionate involvement with her work and commitment to her worried family." The magazine went on to say, "Deftly sidestepping both melodrama and family-values messaging, Poppe imbues the film with enormous emotional resonance, brilliantly grounded by his leading lady...." The Montreal Gazette criticized the film, writing that it was "hobbled by a rather scattershot script" that spouts "platitudes about journalistic duty and media complacency in the face of war," and that the film "engages in some very conventional family melodrama." Awards The film won the Special Grand Prix of the jury at the 2013 Montreal World Film Festival. References External links 2013 films 2013 drama films English-language Norwegian films Norwegian drama films English-language Irish films Irish drama films Films directed by Erik Poppe Films about terrorism Films about war photographers 2010s English-language films
Sasha Belle, also known as Frisbee Jenkins, is the stage name of Jared Breakenridge, a drag performer who competed on season 7 of RuPaul's Drag Race. Career Sasha Belle competed on season 7 of RuPaul's Drag Race. She was the second contestant eliminated. Her drag name is composed of Sasha, in homage to Beyoncé's alter ego Sasha Fierce, and Belle, taken from her drag mother Pretty Belle. The first name of her current drag moniker, Frisbee Jenkins, is likely inspired by the throwing toy of the same name. She has hosted her own drag show at Studio 13, called Sasha Belle's Drag Race. She later become known as Frisbee Jenkins, and has shared adult content on OnlyFans. Personal life Sasha Belle is from Iowa City, Iowa. Filmography Television RuPaul's Drag Race (season 7) See also List of people from Iowa References External links Jared Breakenridge at IMDb Living people American drag queens People from Iowa City, Iowa RuPaul's Drag Race contestants
```java /* * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * published by the Free Software Foundation. Oracle designates this * particular file as subject to the "Classpath" exception as provided * by Oracle in the LICENSE file that accompanied this code. * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). * * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. */ package jdk.graal.compiler.nodes.extended; import static jdk.graal.compiler.nodeinfo.NodeCycles.CYCLES_0; import static jdk.graal.compiler.nodeinfo.NodeSize.SIZE_0; import jdk.graal.compiler.core.common.type.StampFactory; import jdk.graal.compiler.graph.Node; import jdk.graal.compiler.graph.NodeClass; import jdk.graal.compiler.nodeinfo.InputType; import jdk.graal.compiler.nodeinfo.NodeInfo; import jdk.graal.compiler.nodes.FixedWithNextNode; import jdk.graal.compiler.nodes.NodeView; import jdk.graal.compiler.nodes.ValueNode; import jdk.graal.compiler.nodes.spi.Canonicalizable; import jdk.graal.compiler.nodes.spi.CanonicalizerTool; import jdk.graal.compiler.nodes.spi.LIRLowerable; import jdk.graal.compiler.nodes.spi.NodeLIRBuilderTool; import jdk.graal.compiler.nodes.spi.ValueProxy; @NodeInfo(cycles = CYCLES_0, size = SIZE_0, allowedUsageTypes = {InputType.Anchor}) public class FixedValueAnchorNode extends FixedWithNextNode implements LIRLowerable, ValueProxy, GuardingNode, Canonicalizable, AnchoringNode { public static final NodeClass<FixedValueAnchorNode> TYPE = NodeClass.create(FixedValueAnchorNode.class); @OptionalInput ValueNode object; public ValueNode object() { return object; } protected FixedValueAnchorNode(NodeClass<? extends FixedValueAnchorNode> c, ValueNode object) { super(c, object == null ? StampFactory.forVoid() : object.stamp(NodeView.DEFAULT)); this.object = object; } public FixedValueAnchorNode(ValueNode object) { this(TYPE, object); } @Override public boolean inferStamp() { if (object != null) { return updateStamp(stamp.join(object.stamp(NodeView.DEFAULT))); } else { return false; } } @Override public Node canonical(CanonicalizerTool tool) { if (tool.allUsagesAvailable() && hasNoUsages()) { return null; } if (object instanceof FixedValueAnchorNode && ((FixedValueAnchorNode) object).next == this) { return object; } return this; } @NodeIntrinsic public static native Object getObject(Object object); @Override public void generate(NodeLIRBuilderTool generator) { generator.setResult(this, generator.operand(object)); } @Override public ValueNode getOriginalNode() { return object; } @Override public GuardingNode getGuard() { return this; } } ```
The 1916 Chicago Cubs season was the 45th season of the Chicago Cubs franchise, the 41st in the National League and the 1st at Wrigley Field (then known as "Weeghman Park"). The Cubs finished fifth in the National League with a record of 67–86. Regular season Season standings Record vs. opponents Notable transactions August 28, 1916: Heinie Zimmerman and Mickey Doolan were traded by the Cubs to the New York Giants for Larry Doyle, Merwin Jacobson, and Herb Hunter. Roster Player stats Batting Starters by position Note: Pos = Position; G = Games played; AB = At bats; H = Hits; Avg. = Batting average; HR = Home runs; RBI = Runs batted in Other batters Note: G = Games played; AB = At bats; H = Hits; Avg. = Batting average; HR = Home runs; RBI = Runs batted in Pitching Starting pitchers Note: G = Games pitched; IP = Innings pitched; W = Wins; L = Losses; ERA = Earned run average; SO = Strikeouts Other pitchers Note: G = Games pitched; IP = Innings pitched; W = Wins; L = Losses; ERA = Earned run average; SO = Strikeouts References External links 1916 Chicago Cubs season at Baseball Reference Chicago Cubs seasons Chicago Cubs season Chicago Cubs
```yaml {{- /* */}} {{- if .Values.gateway.enabled }} apiVersion: {{ template "common.capabilities.deployment.apiVersion" . }} kind: Deployment metadata: name: {{ include "grafana-mimir.gateway.fullname" . }} namespace: {{ include "common.names.namespace" . | quote }} {{- $versionLabel := dict "app.kubernetes.io/version" ( include "common.images.version" ( dict "imageRoot" .Values.gateway.image "chart" .Chart ) ) }} {{- $labels := include "common.tplvalues.merge" ( dict "values" ( list .Values.commonLabels $versionLabel ) "context" . ) }} labels: {{- include "common.labels.standard" ( dict "customLabels" $labels "context" $ ) | nindent 4 }} app.kubernetes.io/part-of: grafana-mimir app.kubernetes.io/component: gateway {{- if .Values.commonAnnotations }} annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} {{- end }} spec: replicas: {{ .Values.gateway.replicaCount }} {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.gateway.podLabels .Values.commonLabels $versionLabel ) "context" . ) }} selector: matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} app.kubernetes.io/part-of: grafana-mimir app.kubernetes.io/component: gateway {{- if .Values.gateway.updateStrategy }} strategy: {{- toYaml .Values.gateway.updateStrategy | nindent 4 }} {{- end }} template: metadata: labels: {{- include "common.labels.standard" ( dict "customLabels" $podLabels "context" $ ) | nindent 8 }} app.kubernetes.io/part-of: grafana-mimir app.kubernetes.io/component: gateway annotations: checksum/configmap: {{ include (print $.Template.BasePath "/gateway/configmap-http.yaml") . | sha256sum }} {{- if .Values.gateway.podAnnotations }} {{- include "common.tplvalues.render" (dict "value" .Values.gateway.podAnnotations "context" $) | nindent 8 }} {{- end }} spec: {{- include "grafana-mimir.imagePullSecrets" . | nindent 6 }} automountServiceAccountToken: {{ .Values.gateway.automountServiceAccountToken }} {{- if .Values.gateway.hostAliases }} hostAliases: {{- include "common.tplvalues.render" (dict "value" .Values.gateway.hostAliases "context" $) | nindent 8 }} {{- end }} {{- if .Values.gateway.affinity }} affinity: {{- include "common.tplvalues.render" (dict "value" .Values.gateway.affinity "context" $) | nindent 8 }} {{- else }} affinity: podAffinity: {{- include "common.affinities.pods" (dict "type" .Values.gateway.podAffinityPreset "component" "gateway" "customLabels" $podLabels "context" $) | nindent 10 }} podAntiAffinity: {{- include "common.affinities.pods" (dict "type" .Values.gateway.podAntiAffinityPreset "component" "gateway" "customLabels" $podLabels "context" $) | nindent 10 }} nodeAffinity: {{- include "common.affinities.nodes" (dict "type" .Values.gateway.nodeAffinityPreset.type "key" .Values.gateway.nodeAffinityPreset.key "values" .Values.gateway.nodeAffinityPreset.values) | nindent 10 }} {{- end }} {{- if .Values.gateway.nodeSelector }} nodeSelector: {{- include "common.tplvalues.render" (dict "value" .Values.gateway.nodeSelector "context" $) | nindent 8 }} {{- end }} {{- if .Values.gateway.tolerations }} tolerations: {{- include "common.tplvalues.render" (dict "value" .Values.gateway.tolerations "context" $) | nindent 8 }} {{- end }} {{- if .Values.gateway.topologySpreadConstraints }} topologySpreadConstraints: {{- include "common.tplvalues.render" (dict "value" .Values.gateway.topologySpreadConstraints "context" .) | nindent 8 }} {{- end }} {{- if .Values.gateway.priorityClassName }} priorityClassName: {{ .Values.gateway.priorityClassName | quote }} {{- end }} {{- if .Values.gateway.schedulerName }} schedulerName: {{ .Values.gateway.schedulerName }} {{- end }} {{- if .Values.gateway.podSecurityContext.enabled }} securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.gateway.podSecurityContext "context" $) | nindent 8 }} {{- end }} {{- if .Values.gateway.initContainers }} initContainers: {{- include "common.tplvalues.render" (dict "value" .Values.gateway.initContainers "context" $) | nindent 8 }} {{- end }} containers: - name: gateway image: {{ include "grafana-mimir.gateway.image" . }} imagePullPolicy: {{ .Values.gateway.image.pullPolicy | quote }} {{- if .Values.gateway.containerSecurityContext.enabled }} securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.gateway.containerSecurityContext "context" $) | nindent 12 }} {{- end }} {{- if .Values.diagnosticMode.enabled }} command: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.command "context" $) | nindent 12 }} {{- else if .Values.gateway.command }} command: {{- include "common.tplvalues.render" (dict "value" .Values.gateway.command "context" $) | nindent 12 }} {{- else }} command: - /bin/bash - -ec - | # Generate resolver data echo resolver $(awk 'BEGIN{ORS=" "} $1=="nameserver" {print $2}' /etc/resolv.conf) ";" > /opt/bitnami/nginx/conf/resolvers.conf /opt/bitnami/scripts/nginx/entrypoint.sh /opt/bitnami/scripts/nginx/run.sh {{- end }} {{- if .Values.diagnosticMode.enabled }} args: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.args "context" $) | nindent 12 }} {{- else if .Values.gateway.args }} args: {{- include "common.tplvalues.render" (dict "value" .Values.gateway.args "context" $) | nindent 12 }} {{- end }} env: - name: BITNAMI_DEBUG value: {{ ternary "true" "false" .Values.gateway.image.debug | quote }} {{- if .Values.gateway.extraEnvVars }} {{- include "common.tplvalues.render" (dict "value" .Values.gateway.extraEnvVars "context" $) | nindent 12 }} {{- end }} envFrom: {{- if .Values.gateway.extraEnvVarsCM }} - configMapRef: name: {{ include "common.tplvalues.render" (dict "value" .Values.gateway.extraEnvVarsCM "context" $) }} {{- end }} {{- if .Values.gateway.extraEnvVarsSecret }} - secretRef: name: {{ include "common.tplvalues.render" (dict "value" .Values.gateway.extraEnvVarsSecret "context" $) }} {{- end }} {{- if .Values.gateway.lifecycleHooks }} lifecycle: {{- include "common.tplvalues.render" (dict "value" .Values.gateway.lifecycleHooks "context" $) | nindent 12 }} {{- end }} ports: - containerPort: {{ .Values.gateway.containerPorts.http }} name: http {{- if not .Values.diagnosticMode.enabled }} {{- if .Values.gateway.customStartupProbe }} startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.gateway.customStartupProbe "context" $) | nindent 12 }} {{- else if .Values.gateway.startupProbe.enabled }} startupProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.gateway.startupProbe "enabled") "context" $) | nindent 12 }} tcpSocket: port: http {{- end }} {{- if .Values.gateway.customLivenessProbe }} livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.gateway.customLivenessProbe "context" $) | nindent 12 }} {{- else if .Values.gateway.livenessProbe.enabled }} livenessProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.gateway.livenessProbe "enabled") "context" $) | nindent 12 }} tcpSocket: port: http {{- end }} {{- if .Values.gateway.customReadinessProbe }} readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.gateway.customReadinessProbe "context" $) | nindent 12 }} {{- else if .Values.gateway.readinessProbe.enabled }} readinessProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.gateway.readinessProbe "enabled") "context" $) | nindent 12 }} httpGet: path: / port: http {{- end }} {{- end }} {{- if .Values.gateway.resources }} resources: {{- toYaml .Values.gateway.resources | nindent 12 }} {{- else if ne .Values.gateway.resourcesPreset "none" }} resources: {{- include "common.resources.preset" (dict "type" .Values.gateway.resourcesPreset) | nindent 12 }} {{- end }} volumeMounts: - name: empty-dir mountPath: /tmp subPath: tmp-dir - name: empty-dir mountPath: /opt/bitnami/nginx/conf subPath: app-conf-dir - name: config mountPath: /opt/bitnami/nginx/conf/nginx.conf subPath: nginx.conf {{- if .Values.gateway.auth.enabled }} - name: htpasswd mountPath: /bitnami/nginx/secrets/ {{- end }} {{- if .Values.gateway.extraVolumeMounts }} {{- include "common.tplvalues.render" (dict "value" .Values.gateway.extraVolumeMounts "context" $) | nindent 12 }} {{- end }} {{- if .Values.gateway.sidecars }} {{- include "common.tplvalues.render" (dict "value" .Values.gateway.sidecars "context" $) | nindent 8 }} {{- end }} volumes: - name: empty-dir emptyDir: {} - name: config configMap: name: {{ include "grafana-mimir.gateway.fullname" . }} {{- if .Values.gateway.auth.enabled }} - name: htpasswd secret: secretName: {{ include "grafana-mimir.gateway.secretName" . }} items: - key: htpasswd path: .htpasswd {{- end }} {{- if .Values.gateway.extraVolumes }} {{- include "common.tplvalues.render" (dict "value" .Values.gateway.extraVolumes "context" $) | nindent 8 }} {{- end }} {{- end }} ```
Katarina Bartholdson (born 25 February 1941) is a Swedish former tennis player. She also played under her maiden name Katarina Frendelius. A winner of 11 national championships in singles or doubles, Bartholdson made her only Federation Cup appearance in Sweden's debut tie in 1964, against Canada. She won her singles match against Benita Senn, but was beaten in the live doubles rubber, partnering Ulla Sandulf. Bartholdson competed in multiple Wimbledon draws and reached the singles third round in 1963, where she lost to top seed Margaret Smith (later Court). See also List of Sweden Fed Cup team representatives References External links 1941 births Living people Swedish female tennis players
```objective-c #import "GPUImageSoftLightBlendFilter.h" #if TARGET_IPHONE_SIMULATOR || TARGET_OS_IPHONE NSString *const kGPUImageSoftLightBlendFragmentShaderString = SHADER_STRING ( varying highp vec2 textureCoordinate; varying highp vec2 textureCoordinate2; uniform sampler2D inputImageTexture; uniform sampler2D inputImageTexture2; void main() { mediump vec4 base = texture2D(inputImageTexture, textureCoordinate); mediump vec4 overlay = texture2D(inputImageTexture2, textureCoordinate2); lowp float alphaDivisor = base.a + step(base.a, 0.0); // Protect against a divide-by-zero blacking out things in the output gl_FragColor = base * (overlay.a * (base / alphaDivisor) + (2.0 * overlay * (1.0 - (base / alphaDivisor)))) + overlay * (1.0 - base.a) + base * (1.0 - overlay.a); } ); #else NSString *const kGPUImageSoftLightBlendFragmentShaderString = SHADER_STRING ( varying vec2 textureCoordinate; varying vec2 textureCoordinate2; uniform sampler2D inputImageTexture; uniform sampler2D inputImageTexture2; void main() { vec4 base = texture2D(inputImageTexture, textureCoordinate); vec4 overlay = texture2D(inputImageTexture2, textureCoordinate2); float alphaDivisor = base.a + step(base.a, 0.0); // Protect against a divide-by-zero blacking out things in the output gl_FragColor = base * (overlay.a * (base / alphaDivisor) + (2.0 * overlay * (1.0 - (base / alphaDivisor)))) + overlay * (1.0 - base.a) + base * (1.0 - overlay.a); } ); #endif @implementation GPUImageSoftLightBlendFilter - (id)init; { if (!(self = [super initWithFragmentShaderFromString:kGPUImageSoftLightBlendFragmentShaderString])) { return nil; } return self; } @end ```
```c++ // Locale support -*- C++ -*- // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the // Free Software Foundation; either version 3, or (at your option) // any later version. // This library is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // Under Section 7 of GPL version 3, you are granted additional // permissions described in the GCC Runtime Library Exception, version // 3.1, as published by the Free Software Foundation. // a copy of the GCC Runtime Library Exception along with this program; // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see // <path_to_url /** @file bits/locale_facets_nonio.tcc * This is an internal header file, included by other library headers. * Do not attempt to use it directly. @headername{locale} */ #ifndef _LOCALE_FACETS_NONIO_TCC #define _LOCALE_FACETS_NONIO_TCC 1 #pragma GCC system_header namespace std _GLIBCXX_VISIBILITY(default) { _GLIBCXX_BEGIN_NAMESPACE_VERSION template<typename _CharT, bool _Intl> struct __use_cache<__moneypunct_cache<_CharT, _Intl> > { const __moneypunct_cache<_CharT, _Intl>* operator() (const locale& __loc) const { const size_t __i = moneypunct<_CharT, _Intl>::id._M_id(); const locale::facet** __caches = __loc._M_impl->_M_caches; if (!__caches[__i]) { __moneypunct_cache<_CharT, _Intl>* __tmp = 0; __try { __tmp = new __moneypunct_cache<_CharT, _Intl>; __tmp->_M_cache(__loc); } __catch(...) { delete __tmp; __throw_exception_again; } __loc._M_impl->_M_install_cache(__tmp, __i); } return static_cast< const __moneypunct_cache<_CharT, _Intl>*>(__caches[__i]); } }; template<typename _CharT, bool _Intl> void __moneypunct_cache<_CharT, _Intl>::_M_cache(const locale& __loc) { const moneypunct<_CharT, _Intl>& __mp = use_facet<moneypunct<_CharT, _Intl> >(__loc); _M_decimal_point = __mp.decimal_point(); _M_thousands_sep = __mp.thousands_sep(); _M_frac_digits = __mp.frac_digits(); char* __grouping = 0; _CharT* __curr_symbol = 0; _CharT* __positive_sign = 0; _CharT* __negative_sign = 0; __try { const string& __g = __mp.grouping(); _M_grouping_size = __g.size(); __grouping = new char[_M_grouping_size]; __g.copy(__grouping, _M_grouping_size); _M_use_grouping = (_M_grouping_size && static_cast<signed char>(__grouping[0]) > 0 && (__grouping[0] != __gnu_cxx::__numeric_traits<char>::__max)); const basic_string<_CharT>& __cs = __mp.curr_symbol(); _M_curr_symbol_size = __cs.size(); __curr_symbol = new _CharT[_M_curr_symbol_size]; __cs.copy(__curr_symbol, _M_curr_symbol_size); const basic_string<_CharT>& __ps = __mp.positive_sign(); _M_positive_sign_size = __ps.size(); __positive_sign = new _CharT[_M_positive_sign_size]; __ps.copy(__positive_sign, _M_positive_sign_size); const basic_string<_CharT>& __ns = __mp.negative_sign(); _M_negative_sign_size = __ns.size(); __negative_sign = new _CharT[_M_negative_sign_size]; __ns.copy(__negative_sign, _M_negative_sign_size); _M_pos_format = __mp.pos_format(); _M_neg_format = __mp.neg_format(); const ctype<_CharT>& __ct = use_facet<ctype<_CharT> >(__loc); __ct.widen(money_base::_S_atoms, money_base::_S_atoms + money_base::_S_end, _M_atoms); _M_grouping = __grouping; _M_curr_symbol = __curr_symbol; _M_positive_sign = __positive_sign; _M_negative_sign = __negative_sign; _M_allocated = true; } __catch(...) { delete [] __grouping; delete [] __curr_symbol; delete [] __positive_sign; delete [] __negative_sign; __throw_exception_again; } } _GLIBCXX_BEGIN_NAMESPACE_LDBL_OR_CXX11 template<typename _CharT, typename _InIter> template<bool _Intl> _InIter money_get<_CharT, _InIter>:: _M_extract(iter_type __beg, iter_type __end, ios_base& __io, ios_base::iostate& __err, string& __units) const { typedef char_traits<_CharT> __traits_type; typedef typename string_type::size_type size_type; typedef money_base::part part; typedef __moneypunct_cache<_CharT, _Intl> __cache_type; const locale& __loc = __io._M_getloc(); const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); __use_cache<__cache_type> __uc; const __cache_type* __lc = __uc(__loc); const char_type* __lit = __lc->_M_atoms; // Deduced sign. bool __negative = false; // Sign size. size_type __sign_size = 0; // True if sign is mandatory. const bool __mandatory_sign = (__lc->_M_positive_sign_size && __lc->_M_negative_sign_size); // String of grouping info from thousands_sep plucked from __units. string __grouping_tmp; if (__lc->_M_use_grouping) __grouping_tmp.reserve(32); // Last position before the decimal point. int __last_pos = 0; // Separator positions, then, possibly, fractional digits. int __n = 0; // If input iterator is in a valid state. bool __testvalid = true; // Flag marking when a decimal point is found. bool __testdecfound = false; // The tentative returned string is stored here. string __res; __res.reserve(32); const char_type* __lit_zero = __lit + money_base::_S_zero; const money_base::pattern __p = __lc->_M_neg_format; for (int __i = 0; __i < 4 && __testvalid; ++__i) { const part __which = static_cast<part>(__p.field[__i]); switch (__which) { case money_base::symbol: // According to 22.2.6.1.2, p2, symbol is required // if (__io.flags() & ios_base::showbase), otherwise // is optional and consumed only if other characters // are needed to complete the format. if (__io.flags() & ios_base::showbase || __sign_size > 1 || __i == 0 || (__i == 1 && (__mandatory_sign || (static_cast<part>(__p.field[0]) == money_base::sign) || (static_cast<part>(__p.field[2]) == money_base::space))) || (__i == 2 && ((static_cast<part>(__p.field[3]) == money_base::value) || (__mandatory_sign && (static_cast<part>(__p.field[3]) == money_base::sign))))) { const size_type __len = __lc->_M_curr_symbol_size; size_type __j = 0; for (; __beg != __end && __j < __len && *__beg == __lc->_M_curr_symbol[__j]; ++__beg, ++__j); if (__j != __len && (__j || __io.flags() & ios_base::showbase)) __testvalid = false; } break; case money_base::sign: // Sign might not exist, or be more than one character long. if (__lc->_M_positive_sign_size && __beg != __end && *__beg == __lc->_M_positive_sign[0]) { __sign_size = __lc->_M_positive_sign_size; ++__beg; } else if (__lc->_M_negative_sign_size && __beg != __end && *__beg == __lc->_M_negative_sign[0]) { __negative = true; __sign_size = __lc->_M_negative_sign_size; ++__beg; } else if (__lc->_M_positive_sign_size && !__lc->_M_negative_sign_size) // "... if no sign is detected, the result is given the sign // that corresponds to the source of the empty string" __negative = true; else if (__mandatory_sign) __testvalid = false; break; case money_base::value: // Extract digits, remove and stash away the // grouping of found thousands separators. for (; __beg != __end; ++__beg) { const char_type __c = *__beg; const char_type* __q = __traits_type::find(__lit_zero, 10, __c); if (__q != 0) { __res += money_base::_S_atoms[__q - __lit]; ++__n; } else if (__c == __lc->_M_decimal_point && !__testdecfound) { if (__lc->_M_frac_digits <= 0) break; __last_pos = __n; __n = 0; __testdecfound = true; } else if (__lc->_M_use_grouping && __c == __lc->_M_thousands_sep && !__testdecfound) { if (__n) { // Mark position for later analysis. __grouping_tmp += static_cast<char>(__n); __n = 0; } else { __testvalid = false; break; } } else break; } if (__res.empty()) __testvalid = false; break; case money_base::space: // At least one space is required. if (__beg != __end && __ctype.is(ctype_base::space, *__beg)) ++__beg; else __testvalid = false; case money_base::none: // Only if not at the end of the pattern. if (__i != 3) for (; __beg != __end && __ctype.is(ctype_base::space, *__beg); ++__beg); break; } } // Need to get the rest of the sign characters, if they exist. if (__sign_size > 1 && __testvalid) { const char_type* __sign = __negative ? __lc->_M_negative_sign : __lc->_M_positive_sign; size_type __i = 1; for (; __beg != __end && __i < __sign_size && *__beg == __sign[__i]; ++__beg, ++__i); if (__i != __sign_size) __testvalid = false; } if (__testvalid) { // Strip leading zeros. if (__res.size() > 1) { const size_type __first = __res.find_first_not_of('0'); const bool __only_zeros = __first == string::npos; if (__first) __res.erase(0, __only_zeros ? __res.size() - 1 : __first); } // 22.2.6.1.2, p4 if (__negative && __res[0] != '0') __res.insert(__res.begin(), '-'); // Test for grouping fidelity. if (__grouping_tmp.size()) { // Add the ending grouping. __grouping_tmp += static_cast<char>(__testdecfound ? __last_pos : __n); if (!std::__verify_grouping(__lc->_M_grouping, __lc->_M_grouping_size, __grouping_tmp)) __err |= ios_base::failbit; } // Iff not enough digits were supplied after the decimal-point. if (__testdecfound && __n != __lc->_M_frac_digits) __testvalid = false; } // Iff valid sequence is not recognized. if (!__testvalid) __err |= ios_base::failbit; else __units.swap(__res); // Iff no more characters are available. if (__beg == __end) __err |= ios_base::eofbit; return __beg; } #if defined _GLIBCXX_LONG_DOUBLE_COMPAT && defined __LONG_DOUBLE_128__ \ && _GLIBCXX_USE_CXX11_ABI == 0 template<typename _CharT, typename _InIter> _InIter money_get<_CharT, _InIter>:: __do_get(iter_type __beg, iter_type __end, bool __intl, ios_base& __io, ios_base::iostate& __err, double& __units) const { string __str; __beg = __intl ? _M_extract<true>(__beg, __end, __io, __err, __str) : _M_extract<false>(__beg, __end, __io, __err, __str); std::__convert_to_v(__str.c_str(), __units, __err, _S_get_c_locale()); return __beg; } #endif template<typename _CharT, typename _InIter> _InIter money_get<_CharT, _InIter>:: do_get(iter_type __beg, iter_type __end, bool __intl, ios_base& __io, ios_base::iostate& __err, long double& __units) const { string __str; __beg = __intl ? _M_extract<true>(__beg, __end, __io, __err, __str) : _M_extract<false>(__beg, __end, __io, __err, __str); std::__convert_to_v(__str.c_str(), __units, __err, _S_get_c_locale()); return __beg; } template<typename _CharT, typename _InIter> _InIter money_get<_CharT, _InIter>:: do_get(iter_type __beg, iter_type __end, bool __intl, ios_base& __io, ios_base::iostate& __err, string_type& __digits) const { typedef typename string::size_type size_type; const locale& __loc = __io._M_getloc(); const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); string __str; __beg = __intl ? _M_extract<true>(__beg, __end, __io, __err, __str) : _M_extract<false>(__beg, __end, __io, __err, __str); const size_type __len = __str.size(); if (__len) { __digits.resize(__len); __ctype.widen(__str.data(), __str.data() + __len, &__digits[0]); } return __beg; } template<typename _CharT, typename _OutIter> template<bool _Intl> _OutIter money_put<_CharT, _OutIter>:: _M_insert(iter_type __s, ios_base& __io, char_type __fill, const string_type& __digits) const { typedef typename string_type::size_type size_type; typedef money_base::part part; typedef __moneypunct_cache<_CharT, _Intl> __cache_type; const locale& __loc = __io._M_getloc(); const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); __use_cache<__cache_type> __uc; const __cache_type* __lc = __uc(__loc); const char_type* __lit = __lc->_M_atoms; // Determine if negative or positive formats are to be used, and // discard leading negative_sign if it is present. const char_type* __beg = __digits.data(); money_base::pattern __p; const char_type* __sign; size_type __sign_size; if (!(*__beg == __lit[money_base::_S_minus])) { __p = __lc->_M_pos_format; __sign = __lc->_M_positive_sign; __sign_size = __lc->_M_positive_sign_size; } else { __p = __lc->_M_neg_format; __sign = __lc->_M_negative_sign; __sign_size = __lc->_M_negative_sign_size; if (__digits.size()) ++__beg; } // Look for valid numbers in the ctype facet within input digits. size_type __len = __ctype.scan_not(ctype_base::digit, __beg, __beg + __digits.size()) - __beg; if (__len) { // Assume valid input, and attempt to format. // Break down input numbers into base components, as follows: // final_value = grouped units + (decimal point) + (digits) string_type __value; __value.reserve(2 * __len); // Add thousands separators to non-decimal digits, per // grouping rules. long __paddec = __len - __lc->_M_frac_digits; if (__paddec > 0) { if (__lc->_M_frac_digits < 0) __paddec = __len; if (__lc->_M_grouping_size) { __value.assign(2 * __paddec, char_type()); _CharT* __vend = std::__add_grouping(&__value[0], __lc->_M_thousands_sep, __lc->_M_grouping, __lc->_M_grouping_size, __beg, __beg + __paddec); __value.erase(__vend - &__value[0]); } else __value.assign(__beg, __paddec); } // Deal with decimal point, decimal digits. if (__lc->_M_frac_digits > 0) { __value += __lc->_M_decimal_point; if (__paddec >= 0) __value.append(__beg + __paddec, __lc->_M_frac_digits); else { // Have to pad zeros in the decimal position. __value.append(-__paddec, __lit[money_base::_S_zero]); __value.append(__beg, __len); } } // Calculate length of resulting string. const ios_base::fmtflags __f = __io.flags() & ios_base::adjustfield; __len = __value.size() + __sign_size; __len += ((__io.flags() & ios_base::showbase) ? __lc->_M_curr_symbol_size : 0); string_type __res; __res.reserve(2 * __len); const size_type __width = static_cast<size_type>(__io.width()); const bool __testipad = (__f == ios_base::internal && __len < __width); // Fit formatted digits into the required pattern. for (int __i = 0; __i < 4; ++__i) { const part __which = static_cast<part>(__p.field[__i]); switch (__which) { case money_base::symbol: if (__io.flags() & ios_base::showbase) __res.append(__lc->_M_curr_symbol, __lc->_M_curr_symbol_size); break; case money_base::sign: // Sign might not exist, or be more than one // character long. In that case, add in the rest // below. if (__sign_size) __res += __sign[0]; break; case money_base::value: __res += __value; break; case money_base::space: // At least one space is required, but if internal // formatting is required, an arbitrary number of // fill spaces will be necessary. if (__testipad) __res.append(__width - __len, __fill); else __res += __fill; break; case money_base::none: if (__testipad) __res.append(__width - __len, __fill); break; } } // Special case of multi-part sign parts. if (__sign_size > 1) __res.append(__sign + 1, __sign_size - 1); // Pad, if still necessary. __len = __res.size(); if (__width > __len) { if (__f == ios_base::left) // After. __res.append(__width - __len, __fill); else // Before. __res.insert(0, __width - __len, __fill); __len = __width; } // Write resulting, fully-formatted string to output iterator. __s = std::__write(__s, __res.data(), __len); } __io.width(0); return __s; } #if defined _GLIBCXX_LONG_DOUBLE_COMPAT && defined __LONG_DOUBLE_128__ \ && _GLIBCXX_USE_CXX11_ABI == 0 template<typename _CharT, typename _OutIter> _OutIter money_put<_CharT, _OutIter>:: __do_put(iter_type __s, bool __intl, ios_base& __io, char_type __fill, double __units) const { return this->do_put(__s, __intl, __io, __fill, (long double) __units); } #endif template<typename _CharT, typename _OutIter> _OutIter money_put<_CharT, _OutIter>:: do_put(iter_type __s, bool __intl, ios_base& __io, char_type __fill, long double __units) const { const locale __loc = __io.getloc(); const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); #ifdef _GLIBCXX_USE_C99 // First try a buffer perhaps big enough. int __cs_size = 64; char* __cs = static_cast<char*>(__builtin_alloca(__cs_size)); // _GLIBCXX_RESOLVE_LIB_DEFECTS // 328. Bad sprintf format modifier in money_put<>::do_put() int __len = std::__convert_from_v(_S_get_c_locale(), __cs, __cs_size, "%.*Lf", 0, __units); // If the buffer was not large enough, try again with the correct size. if (__len >= __cs_size) { __cs_size = __len + 1; __cs = static_cast<char*>(__builtin_alloca(__cs_size)); __len = std::__convert_from_v(_S_get_c_locale(), __cs, __cs_size, "%.*Lf", 0, __units); } #else // max_exponent10 + 1 for the integer part, + 2 for sign and '\0'. const int __cs_size = __gnu_cxx::__numeric_traits<long double>::__max_exponent10 + 3; char* __cs = static_cast<char*>(__builtin_alloca(__cs_size)); int __len = std::__convert_from_v(_S_get_c_locale(), __cs, 0, "%.*Lf", 0, __units); #endif string_type __digits(__len, char_type()); __ctype.widen(__cs, __cs + __len, &__digits[0]); return __intl ? _M_insert<true>(__s, __io, __fill, __digits) : _M_insert<false>(__s, __io, __fill, __digits); } template<typename _CharT, typename _OutIter> _OutIter money_put<_CharT, _OutIter>:: do_put(iter_type __s, bool __intl, ios_base& __io, char_type __fill, const string_type& __digits) const { return __intl ? _M_insert<true>(__s, __io, __fill, __digits) : _M_insert<false>(__s, __io, __fill, __digits); } _GLIBCXX_END_NAMESPACE_LDBL_OR_CXX11 // NB: Not especially useful. Without an ios_base object or some // kind of locale reference, we are left clawing at the air where // the side of the mountain used to be... template<typename _CharT, typename _InIter> time_base::dateorder time_get<_CharT, _InIter>::do_date_order() const { return time_base::no_order; } // Expand a strftime format string and parse it. E.g., do_get_date() may // pass %m/%d/%Y => extracted characters. template<typename _CharT, typename _InIter> _InIter time_get<_CharT, _InIter>:: _M_extract_via_format(iter_type __beg, iter_type __end, ios_base& __io, ios_base::iostate& __err, tm* __tm, const _CharT* __format) const { const locale& __loc = __io._M_getloc(); const __timepunct<_CharT>& __tp = use_facet<__timepunct<_CharT> >(__loc); const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); const size_t __len = char_traits<_CharT>::length(__format); ios_base::iostate __tmperr = ios_base::goodbit; size_t __i = 0; for (; __beg != __end && __i < __len && !__tmperr; ++__i) { if (__ctype.narrow(__format[__i], 0) == '%') { // Verify valid formatting code, attempt to extract. char __c = __ctype.narrow(__format[++__i], 0); int __mem = 0; if (__c == 'E' || __c == 'O') __c = __ctype.narrow(__format[++__i], 0); switch (__c) { const char* __cs; _CharT __wcs[10]; case 'a': // Abbreviated weekday name [tm_wday] const char_type* __days1[7]; __tp._M_days_abbreviated(__days1); __beg = _M_extract_name(__beg, __end, __tm->tm_wday, __days1, 7, __io, __tmperr); break; case 'A': // Weekday name [tm_wday]. const char_type* __days2[7]; __tp._M_days(__days2); __beg = _M_extract_name(__beg, __end, __tm->tm_wday, __days2, 7, __io, __tmperr); break; case 'h': case 'b': // Abbreviated month name [tm_mon] const char_type* __months1[12]; __tp._M_months_abbreviated(__months1); __beg = _M_extract_name(__beg, __end, __tm->tm_mon, __months1, 12, __io, __tmperr); break; case 'B': // Month name [tm_mon]. const char_type* __months2[12]; __tp._M_months(__months2); __beg = _M_extract_name(__beg, __end, __tm->tm_mon, __months2, 12, __io, __tmperr); break; case 'c': // Default time and date representation. const char_type* __dt[2]; __tp._M_date_time_formats(__dt); __beg = _M_extract_via_format(__beg, __end, __io, __tmperr, __tm, __dt[0]); break; case 'd': // Day [01, 31]. [tm_mday] __beg = _M_extract_num(__beg, __end, __tm->tm_mday, 1, 31, 2, __io, __tmperr); break; case 'e': // Day [1, 31], with single digits preceded by // space. [tm_mday] if (__ctype.is(ctype_base::space, *__beg)) __beg = _M_extract_num(++__beg, __end, __tm->tm_mday, 1, 9, 1, __io, __tmperr); else __beg = _M_extract_num(__beg, __end, __tm->tm_mday, 10, 31, 2, __io, __tmperr); break; case 'D': // Equivalent to %m/%d/%y.[tm_mon, tm_mday, tm_year] __cs = "%m/%d/%y"; __ctype.widen(__cs, __cs + 9, __wcs); __beg = _M_extract_via_format(__beg, __end, __io, __tmperr, __tm, __wcs); break; case 'H': // Hour [00, 23]. [tm_hour] __beg = _M_extract_num(__beg, __end, __tm->tm_hour, 0, 23, 2, __io, __tmperr); break; case 'I': // Hour [01, 12]. [tm_hour] __beg = _M_extract_num(__beg, __end, __tm->tm_hour, 1, 12, 2, __io, __tmperr); break; case 'm': // Month [01, 12]. [tm_mon] __beg = _M_extract_num(__beg, __end, __mem, 1, 12, 2, __io, __tmperr); if (!__tmperr) __tm->tm_mon = __mem - 1; break; case 'M': // Minute [00, 59]. [tm_min] __beg = _M_extract_num(__beg, __end, __tm->tm_min, 0, 59, 2, __io, __tmperr); break; case 'n': if (__ctype.narrow(*__beg, 0) == '\n') ++__beg; else __tmperr |= ios_base::failbit; break; case 'R': // Equivalent to (%H:%M). __cs = "%H:%M"; __ctype.widen(__cs, __cs + 6, __wcs); __beg = _M_extract_via_format(__beg, __end, __io, __tmperr, __tm, __wcs); break; case 'S': // Seconds. [tm_sec] // [00, 60] in C99 (one leap-second), [00, 61] in C89. #ifdef _GLIBCXX_USE_C99 __beg = _M_extract_num(__beg, __end, __tm->tm_sec, 0, 60, 2, #else __beg = _M_extract_num(__beg, __end, __tm->tm_sec, 0, 61, 2, #endif __io, __tmperr); break; case 't': if (__ctype.narrow(*__beg, 0) == '\t') ++__beg; else __tmperr |= ios_base::failbit; break; case 'T': // Equivalent to (%H:%M:%S). __cs = "%H:%M:%S"; __ctype.widen(__cs, __cs + 9, __wcs); __beg = _M_extract_via_format(__beg, __end, __io, __tmperr, __tm, __wcs); break; case 'x': // Locale's date. const char_type* __dates[2]; __tp._M_date_formats(__dates); __beg = _M_extract_via_format(__beg, __end, __io, __tmperr, __tm, __dates[0]); break; case 'X': // Locale's time. const char_type* __times[2]; __tp._M_time_formats(__times); __beg = _M_extract_via_format(__beg, __end, __io, __tmperr, __tm, __times[0]); break; case 'y': case 'C': // C99 // Two digit year. case 'Y': // Year [1900). // NB: We parse either two digits, implicitly years since // 1900, or 4 digits, full year. In both cases we can // reconstruct [tm_year]. See also libstdc++/26701. __beg = _M_extract_num(__beg, __end, __mem, 0, 9999, 4, __io, __tmperr); if (!__tmperr) __tm->tm_year = __mem < 0 ? __mem + 100 : __mem - 1900; break; case 'Z': // Timezone info. if (__ctype.is(ctype_base::upper, *__beg)) { int __tmp; __beg = _M_extract_name(__beg, __end, __tmp, __timepunct_cache<_CharT>::_S_timezones, 14, __io, __tmperr); // GMT requires special effort. if (__beg != __end && !__tmperr && __tmp == 0 && (*__beg == __ctype.widen('-') || *__beg == __ctype.widen('+'))) { __beg = _M_extract_num(__beg, __end, __tmp, 0, 23, 2, __io, __tmperr); __beg = _M_extract_num(__beg, __end, __tmp, 0, 59, 2, __io, __tmperr); } } else __tmperr |= ios_base::failbit; break; default: // Not recognized. __tmperr |= ios_base::failbit; } } else { // Verify format and input match, extract and discard. if (__format[__i] == *__beg) ++__beg; else __tmperr |= ios_base::failbit; } } if (__tmperr || __i != __len) __err |= ios_base::failbit; return __beg; } template<typename _CharT, typename _InIter> _InIter time_get<_CharT, _InIter>:: _M_extract_num(iter_type __beg, iter_type __end, int& __member, int __min, int __max, size_t __len, ios_base& __io, ios_base::iostate& __err) const { const locale& __loc = __io._M_getloc(); const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); // As-is works for __len = 1, 2, 4, the values actually used. int __mult = __len == 2 ? 10 : (__len == 4 ? 1000 : 1); ++__min; size_t __i = 0; int __value = 0; for (; __beg != __end && __i < __len; ++__beg, ++__i) { const char __c = __ctype.narrow(*__beg, '*'); if (__c >= '0' && __c <= '9') { __value = __value * 10 + (__c - '0'); const int __valuec = __value * __mult; if (__valuec > __max || __valuec + __mult < __min) break; __mult /= 10; } else break; } if (__i == __len) __member = __value; // Special encoding for do_get_year, 'y', and 'Y' above. else if (__len == 4 && __i == 2) __member = __value - 100; else __err |= ios_base::failbit; return __beg; } // Assumptions: // All elements in __names are unique. template<typename _CharT, typename _InIter> _InIter time_get<_CharT, _InIter>:: _M_extract_name(iter_type __beg, iter_type __end, int& __member, const _CharT** __names, size_t __indexlen, ios_base& __io, ios_base::iostate& __err) const { typedef char_traits<_CharT> __traits_type; const locale& __loc = __io._M_getloc(); const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); int* __matches = static_cast<int*>(__builtin_alloca(sizeof(int) * __indexlen)); size_t __nmatches = 0; size_t __pos = 0; bool __testvalid = true; const char_type* __name; // Look for initial matches. // NB: Some of the locale data is in the form of all lowercase // names, and some is in the form of initially-capitalized // names. Look for both. if (__beg != __end) { const char_type __c = *__beg; for (size_t __i1 = 0; __i1 < __indexlen; ++__i1) if (__c == __names[__i1][0] || __c == __ctype.toupper(__names[__i1][0])) __matches[__nmatches++] = __i1; } while (__nmatches > 1) { // Find smallest matching string. size_t __minlen = __traits_type::length(__names[__matches[0]]); for (size_t __i2 = 1; __i2 < __nmatches; ++__i2) __minlen = std::min(__minlen, __traits_type::length(__names[__matches[__i2]])); ++__beg, ++__pos; if (__pos < __minlen && __beg != __end) for (size_t __i3 = 0; __i3 < __nmatches;) { __name = __names[__matches[__i3]]; if (!(__name[__pos] == *__beg)) __matches[__i3] = __matches[--__nmatches]; else ++__i3; } else break; } if (__nmatches == 1) { // Make sure found name is completely extracted. ++__beg, ++__pos; __name = __names[__matches[0]]; const size_t __len = __traits_type::length(__name); while (__pos < __len && __beg != __end && __name[__pos] == *__beg) ++__beg, ++__pos; if (__len == __pos) __member = __matches[0]; else __testvalid = false; } else __testvalid = false; if (!__testvalid) __err |= ios_base::failbit; return __beg; } template<typename _CharT, typename _InIter> _InIter time_get<_CharT, _InIter>:: _M_extract_wday_or_month(iter_type __beg, iter_type __end, int& __member, const _CharT** __names, size_t __indexlen, ios_base& __io, ios_base::iostate& __err) const { typedef char_traits<_CharT> __traits_type; const locale& __loc = __io._M_getloc(); const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); int* __matches = static_cast<int*>(__builtin_alloca(2 * sizeof(int) * __indexlen)); size_t __nmatches = 0; size_t* __matches_lengths = 0; size_t __pos = 0; if (__beg != __end) { const char_type __c = *__beg; for (size_t __i = 0; __i < 2 * __indexlen; ++__i) if (__c == __names[__i][0] || __c == __ctype.toupper(__names[__i][0])) __matches[__nmatches++] = __i; } if (__nmatches) { ++__beg, ++__pos; __matches_lengths = static_cast<size_t*>(__builtin_alloca(sizeof(size_t) * __nmatches)); for (size_t __i = 0; __i < __nmatches; ++__i) __matches_lengths[__i] = __traits_type::length(__names[__matches[__i]]); } for (; __beg != __end; ++__beg, ++__pos) { size_t __nskipped = 0; const char_type __c = *__beg; for (size_t __i = 0; __i < __nmatches;) { const char_type* __name = __names[__matches[__i]]; if (__pos >= __matches_lengths[__i]) ++__nskipped, ++__i; else if (!(__name[__pos] == __c)) { --__nmatches; __matches[__i] = __matches[__nmatches]; __matches_lengths[__i] = __matches_lengths[__nmatches]; } else ++__i; } if (__nskipped == __nmatches) break; } if ((__nmatches == 1 && __matches_lengths[0] == __pos) || (__nmatches == 2 && (__matches_lengths[0] == __pos || __matches_lengths[1] == __pos))) __member = (__matches[0] >= __indexlen ? __matches[0] - __indexlen : __matches[0]); else __err |= ios_base::failbit; return __beg; } template<typename _CharT, typename _InIter> _InIter time_get<_CharT, _InIter>:: do_get_time(iter_type __beg, iter_type __end, ios_base& __io, ios_base::iostate& __err, tm* __tm) const { const locale& __loc = __io._M_getloc(); const __timepunct<_CharT>& __tp = use_facet<__timepunct<_CharT> >(__loc); const char_type* __times[2]; __tp._M_time_formats(__times); __beg = _M_extract_via_format(__beg, __end, __io, __err, __tm, __times[0]); if (__beg == __end) __err |= ios_base::eofbit; return __beg; } template<typename _CharT, typename _InIter> _InIter time_get<_CharT, _InIter>:: do_get_date(iter_type __beg, iter_type __end, ios_base& __io, ios_base::iostate& __err, tm* __tm) const { const locale& __loc = __io._M_getloc(); const __timepunct<_CharT>& __tp = use_facet<__timepunct<_CharT> >(__loc); const char_type* __dates[2]; __tp._M_date_formats(__dates); __beg = _M_extract_via_format(__beg, __end, __io, __err, __tm, __dates[0]); if (__beg == __end) __err |= ios_base::eofbit; return __beg; } template<typename _CharT, typename _InIter> _InIter time_get<_CharT, _InIter>:: do_get_weekday(iter_type __beg, iter_type __end, ios_base& __io, ios_base::iostate& __err, tm* __tm) const { const locale& __loc = __io._M_getloc(); const __timepunct<_CharT>& __tp = use_facet<__timepunct<_CharT> >(__loc); const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); const char_type* __days[14]; __tp._M_days_abbreviated(__days); __tp._M_days(__days + 7); int __tmpwday; ios_base::iostate __tmperr = ios_base::goodbit; __beg = _M_extract_wday_or_month(__beg, __end, __tmpwday, __days, 7, __io, __tmperr); if (!__tmperr) __tm->tm_wday = __tmpwday; else __err |= ios_base::failbit; if (__beg == __end) __err |= ios_base::eofbit; return __beg; } template<typename _CharT, typename _InIter> _InIter time_get<_CharT, _InIter>:: do_get_monthname(iter_type __beg, iter_type __end, ios_base& __io, ios_base::iostate& __err, tm* __tm) const { const locale& __loc = __io._M_getloc(); const __timepunct<_CharT>& __tp = use_facet<__timepunct<_CharT> >(__loc); const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); const char_type* __months[24]; __tp._M_months_abbreviated(__months); __tp._M_months(__months + 12); int __tmpmon; ios_base::iostate __tmperr = ios_base::goodbit; __beg = _M_extract_wday_or_month(__beg, __end, __tmpmon, __months, 12, __io, __tmperr); if (!__tmperr) __tm->tm_mon = __tmpmon; else __err |= ios_base::failbit; if (__beg == __end) __err |= ios_base::eofbit; return __beg; } template<typename _CharT, typename _InIter> _InIter time_get<_CharT, _InIter>:: do_get_year(iter_type __beg, iter_type __end, ios_base& __io, ios_base::iostate& __err, tm* __tm) const { const locale& __loc = __io._M_getloc(); const ctype<_CharT>& __ctype = use_facet<ctype<_CharT> >(__loc); int __tmpyear; ios_base::iostate __tmperr = ios_base::goodbit; __beg = _M_extract_num(__beg, __end, __tmpyear, 0, 9999, 4, __io, __tmperr); if (!__tmperr) __tm->tm_year = __tmpyear < 0 ? __tmpyear + 100 : __tmpyear - 1900; else __err |= ios_base::failbit; if (__beg == __end) __err |= ios_base::eofbit; return __beg; } #if __cplusplus >= 201103L template<typename _CharT, typename _InIter> inline _InIter time_get<_CharT, _InIter>:: get(iter_type __s, iter_type __end, ios_base& __io, ios_base::iostate& __err, tm* __tm, const char_type* __fmt, const char_type* __fmtend) const { const locale& __loc = __io._M_getloc(); ctype<_CharT> const& __ctype = use_facet<ctype<_CharT> >(__loc); __err = ios_base::goodbit; while (__fmt != __fmtend && __err == ios_base::goodbit) { if (__s == __end) { __err = ios_base::eofbit | ios_base::failbit; break; } else if (__ctype.narrow(*__fmt, 0) == '%') { char __format; char __mod = 0; if (++__fmt == __fmtend) { __err = ios_base::failbit; break; } const char __c = __ctype.narrow(*__fmt, 0); if (__c != 'E' && __c != 'O') __format = __c; else if (++__fmt != __fmtend) { __mod = __c; __format = __ctype.narrow(*__fmt, 0); } else { __err = ios_base::failbit; break; } __s = this->do_get(__s, __end, __io, __err, __tm, __format, __mod); ++__fmt; } else if (__ctype.is(ctype_base::space, *__fmt)) { ++__fmt; while (__fmt != __fmtend && __ctype.is(ctype_base::space, *__fmt)) ++__fmt; while (__s != __end && __ctype.is(ctype_base::space, *__s)) ++__s; } // TODO real case-insensitive comparison else if (__ctype.tolower(*__s) == __ctype.tolower(*__fmt) || __ctype.toupper(*__s) == __ctype.toupper(*__fmt)) { ++__s; ++__fmt; } else { __err = ios_base::failbit; break; } } return __s; } template<typename _CharT, typename _InIter> inline _InIter time_get<_CharT, _InIter>:: do_get(iter_type __beg, iter_type __end, ios_base& __io, ios_base::iostate& __err, tm* __tm, char __format, char __mod) const { const locale& __loc = __io._M_getloc(); ctype<_CharT> const& __ctype = use_facet<ctype<_CharT> >(__loc); __err = ios_base::goodbit; char_type __fmt[4]; __fmt[0] = __ctype.widen('%'); if (!__mod) { __fmt[1] = __format; __fmt[2] = char_type(); } else { __fmt[1] = __mod; __fmt[2] = __format; __fmt[3] = char_type(); } __beg = _M_extract_via_format(__beg, __end, __io, __err, __tm, __fmt); if (__beg == __end) __err |= ios_base::eofbit; return __beg; } #endif // __cplusplus >= 201103L template<typename _CharT, typename _OutIter> _OutIter time_put<_CharT, _OutIter>:: put(iter_type __s, ios_base& __io, char_type __fill, const tm* __tm, const _CharT* __beg, const _CharT* __end) const { const locale& __loc = __io._M_getloc(); ctype<_CharT> const& __ctype = use_facet<ctype<_CharT> >(__loc); for (; __beg != __end; ++__beg) if (__ctype.narrow(*__beg, 0) != '%') { *__s = *__beg; ++__s; } else if (++__beg != __end) { char __format; char __mod = 0; const char __c = __ctype.narrow(*__beg, 0); if (__c != 'E' && __c != 'O') __format = __c; else if (++__beg != __end) { __mod = __c; __format = __ctype.narrow(*__beg, 0); } else break; __s = this->do_put(__s, __io, __fill, __tm, __format, __mod); } else break; return __s; } template<typename _CharT, typename _OutIter> _OutIter time_put<_CharT, _OutIter>:: do_put(iter_type __s, ios_base& __io, char_type, const tm* __tm, char __format, char __mod) const { const locale& __loc = __io._M_getloc(); ctype<_CharT> const& __ctype = use_facet<ctype<_CharT> >(__loc); __timepunct<_CharT> const& __tp = use_facet<__timepunct<_CharT> >(__loc); // NB: This size is arbitrary. Should this be a data member, // initialized at construction? const size_t __maxlen = 128; char_type __res[__maxlen]; // NB: In IEE 1003.1-200x, and perhaps other locale models, it // is possible that the format character will be longer than one // character. Possibilities include 'E' or 'O' followed by a // format character: if __mod is not the default argument, assume // it's a valid modifier. char_type __fmt[4]; __fmt[0] = __ctype.widen('%'); if (!__mod) { __fmt[1] = __format; __fmt[2] = char_type(); } else { __fmt[1] = __mod; __fmt[2] = __format; __fmt[3] = char_type(); } __tp._M_put(__res, __maxlen, __fmt, __tm); // Write resulting, fully-formatted string to output iterator. return std::__write(__s, __res, char_traits<char_type>::length(__res)); } // Inhibit implicit instantiations for required instantiations, // which are defined via explicit instantiations elsewhere. #if _GLIBCXX_EXTERN_TEMPLATE extern template class moneypunct<char, false>; extern template class moneypunct<char, true>; extern template class moneypunct_byname<char, false>; extern template class moneypunct_byname<char, true>; extern template class _GLIBCXX_NAMESPACE_LDBL_OR_CXX11 money_get<char>; extern template class _GLIBCXX_NAMESPACE_LDBL_OR_CXX11 money_put<char>; extern template class __timepunct<char>; extern template class time_put<char>; extern template class time_put_byname<char>; extern template class time_get<char>; extern template class time_get_byname<char>; extern template class messages<char>; extern template class messages_byname<char>; extern template const moneypunct<char, true>& use_facet<moneypunct<char, true> >(const locale&); extern template const moneypunct<char, false>& use_facet<moneypunct<char, false> >(const locale&); extern template const money_put<char>& use_facet<money_put<char> >(const locale&); extern template const money_get<char>& use_facet<money_get<char> >(const locale&); extern template const __timepunct<char>& use_facet<__timepunct<char> >(const locale&); extern template const time_put<char>& use_facet<time_put<char> >(const locale&); extern template const time_get<char>& use_facet<time_get<char> >(const locale&); extern template const messages<char>& use_facet<messages<char> >(const locale&); extern template bool has_facet<moneypunct<char> >(const locale&); extern template bool has_facet<money_put<char> >(const locale&); extern template bool has_facet<money_get<char> >(const locale&); extern template bool has_facet<__timepunct<char> >(const locale&); extern template bool has_facet<time_put<char> >(const locale&); extern template bool has_facet<time_get<char> >(const locale&); extern template bool has_facet<messages<char> >(const locale&); #ifdef _GLIBCXX_USE_WCHAR_T extern template class moneypunct<wchar_t, false>; extern template class moneypunct<wchar_t, true>; extern template class moneypunct_byname<wchar_t, false>; extern template class moneypunct_byname<wchar_t, true>; extern template class _GLIBCXX_NAMESPACE_LDBL_OR_CXX11 money_get<wchar_t>; extern template class _GLIBCXX_NAMESPACE_LDBL_OR_CXX11 money_put<wchar_t>; extern template class __timepunct<wchar_t>; extern template class time_put<wchar_t>; extern template class time_put_byname<wchar_t>; extern template class time_get<wchar_t>; extern template class time_get_byname<wchar_t>; extern template class messages<wchar_t>; extern template class messages_byname<wchar_t>; extern template const moneypunct<wchar_t, true>& use_facet<moneypunct<wchar_t, true> >(const locale&); extern template const moneypunct<wchar_t, false>& use_facet<moneypunct<wchar_t, false> >(const locale&); extern template const money_put<wchar_t>& use_facet<money_put<wchar_t> >(const locale&); extern template const money_get<wchar_t>& use_facet<money_get<wchar_t> >(const locale&); extern template const __timepunct<wchar_t>& use_facet<__timepunct<wchar_t> >(const locale&); extern template const time_put<wchar_t>& use_facet<time_put<wchar_t> >(const locale&); extern template const time_get<wchar_t>& use_facet<time_get<wchar_t> >(const locale&); extern template const messages<wchar_t>& use_facet<messages<wchar_t> >(const locale&); extern template bool has_facet<moneypunct<wchar_t> >(const locale&); extern template bool has_facet<money_put<wchar_t> >(const locale&); extern template bool has_facet<money_get<wchar_t> >(const locale&); extern template bool has_facet<__timepunct<wchar_t> >(const locale&); extern template bool has_facet<time_put<wchar_t> >(const locale&); extern template bool has_facet<time_get<wchar_t> >(const locale&); extern template bool has_facet<messages<wchar_t> >(const locale&); #endif #endif _GLIBCXX_END_NAMESPACE_VERSION } // namespace std #endif ```
Jesús Javier Gómez Mercado (, born 6 August 1984) is a Venezuelan footballer that currently plays for Estudiantes de Mérida as an attacking midfielder or also as a striker. Club career Product of Estudiantes de Mérida youth ranks, Gómez made his professional debut in 2004, breaking out the first team in the 2005–06 season, where played very well, that sealed his sale to Moroccan side Raja Casablanca. However, failing to repeat his performances, he joined Syrian club Al-Ittihad, where he had rematch. On 12 March 2008, the player made his AFC Champions League debut in a 2–0 win over Sepahan, where scored the first goal after a free kick. In June 2008, Gómez returned to Venezuela and joined powerhouse club Caracas, where he won his first professional title (2008–09 Primera División) and was part of the Copa Libertadores' historic squad nicknamed "Los Rojos de Ávila" that was the first Venezuelan team to reach the quarterfinals of the competition. Gómez was selected by the FVF, clubs and players as Primera División most valuable player. In early 2011, Jupiler League club Lierse signed Gómez for an undisclosed fee. However, he failed to play at the Belgian club, joining Wadi Degla of Egypt on loan, where he scored two goals in five EPL games. After a frustrating spell abroad, he returned to Caracas, joining ACD Lara in mid-2012. After one season at the Lara–based club, on 13 June 2013, he rescinded his contract, and joined Mexican club Delfines del Carmen. International career In August 2005, Gómez received a call-up to the Venezuela squad from coach Richard Paez, making his debut on 17 August in a 3–1 friendly match defeat against Ecuador, and scoring his first goal on 1 March 2006 during another friendly against Colombia in a 1–1 draw played in Maracaibo at Pachencho Romero. International goals Honours Club Caracas Primera División (2): 2008–09, 2009–10 Copa Venezuela (1): 2009 Individual Venezuelan Primera División Most Valuable Player (1): 2009–10 References External links SportsYA profile 1984 births Living people Sportspeople from Maracay Venezuelan men's footballers Venezuelan expatriate men's footballers Estudiantes de Mérida players Raja CA players Al-Ittihad SC Aleppo players Caracas FC players Lierse S.K. players Wadi Degla S.C. players Asociación Civil Deportivo Lara players Dorados de Sinaloa footballers Club Necaxa footballers Atlante F.C. footballers Atlético Venezuela C.F. players Venezuelan Primera División players Egyptian Premier League players Ascenso MX players Liga MX players Expatriate men's footballers in Morocco Expatriate men's footballers in Syria Expatriate men's footballers in Egypt Expatriate men's footballers in Belgium Expatriate men's footballers in Mexico Venezuelan expatriate sportspeople in Egypt Venezuelan expatriate sportspeople in Morocco Venezuelan expatriate sportspeople in Syria Venezuelan expatriate sportspeople in Belgium Venezuelan expatriate sportspeople in Mexico Men's association football forwards Syrian Premier League players Venezuela men's international footballers